Tuesday, March 23, 2010

script C++ sTudent login

#include
#include
typedef struct Date{
int Hari [10];
int dd;
char mm[15];
int yyyy;
}user1;
typedef struct Time{
int h;
int m;
int s;
}time;
typedef struct Login{
char ID;
Time waktuLogin;
Date tglLogin;
}login;
int main(){
Login user1;
printf("USER 1\n");
printf("Tanggal Login\n");
printf("\nID : ");scanf("%d",&user1.ID);
printf("Hari : ");scanf("%s",&user1.tglLogin.Hari);
printf("Tangal : ");scanf("%d",&user1.tglLogin.dd);
printf("Bulan : ");scanf("%s",&user1.tglLogin.mm);
printf("Tahun : ");scanf("%d",&user1.tglLogin.yyyy);
printf("\nWaktu Login\n");
printf("\nJam : ");scanf("%d",&user1.waktuLogin.h);
printf("Menit : ");scanf("%d",&user1.waktuLogin.m);
printf("Detik : ");scanf("%d",&user1.waktuLogin.s);
printf("\n========Terimakasih========");
printf("\nData Anda :\n");
printf("ID : %d\n",user1.ID);
printf("Date : %s %d-%s-%d\n",user1.tglLogin.Hari,user1.tglLogin.dd,user1.tglLogin.mm,user1.tglLogin.yyyy);
printf("ID : %d:%d:%d\n",user1.waktuLogin.h,user1.waktuLogin.m,user1.waktuLogin.s);
getch();
}

1 komentar:

Anonymous said...

makasih banyak
info nya bagus

Post a Comment

 
Trends K N A Copyright © 2009
Fresh Girly Blogger Template Designed by Herro | Powered By Blogger