/digwat.cpp //demonstrate a sleep #include <iostream> #include <conio> #include <dos> void main() { cout<<"\t\t-------------------------"<<endl; cout<<"\t\tWELCOME TO KASHI WATCH.COM"<<endl; cout<<"\t\t-------------------------"<<endl<<endl<<endl; cout<<"ENTER FORMAT PLEASE"<<endl<<endl<<endl; cout<<" 1 FOR 12-HOURS FORMAT WATCH"<<endl; cout<<" 2 FOR 24-HOURS FORMAT WATCH"<<endl; int z; cin>>z; clrscr(); switch (z) { case 1: char q[3]; cout<<"ENTER MODE (AM/PM)"<<endl; cin>>q; int a,b,c,d,e,f,r; for(r=0;r<=1;r++) { for(a=0;a<=0;a++) for(b=0;b<=9;b++) for(c=0;c<=5;c++) for(d=0;d<=9;d++) for(e=0;e<=5;e++) for(f=0;f<=9;f++) { sleep(1); clrscr(); cout<<a<<b<<":"<<c<<d<<":"<<e<<f<<q<<endl; for(int P=1;P<=9;P++) if(b==P && a==0 && c==0 && d==0 && e==0 && f==0) cout<<"\a"<<endl; } { for(a=1;a<=1;a++) for(b=0;b<=2;b++) for(c=0;c<=5;c++) for(d=0;d<=9;d++) for(e=0;e<=5;e++) for(f=0;f<=9;f++) { sleep(1); clrscr(); cout<<a<<b<<":"<<c<<d<<":"<<e<<f<<q<<endl; for(int p=0;p<=2;p++) for(int k=1;k<=1;k++) if(b==p && a==k && c==0 && d==0 && e==0 && f==0) cout<<"\a"<<endl; } } } break; case 2: for(a=0;a<=1;a++) for(b=0;b<=9;b++) for(c=0;c<=5;c++) for(d=0;d<=9;d++) for(e=0;e<=5;e++) for(f=0;f<=9;f++) { sleep(1); clrscr(); cout<<a<<b<<":"<<c<<d<<":"<<e<<f<<endl; for(int p=1;p<=9;p++) for(int k=0;k<=1;k++) if(b==p && a==k && c==0 && d==0 && e==0 && f==0) cout<<"\a"<<endl; } { for(a=2;a<=2;a++) for(b=0;b<=3;b++) for(c=0;c<=5;c++) for(d=0;d<=9;d++) for(e=0;e<=5;e++) for(f=0;f<=9;f++) { sleep(1); clrscr(); cout<<a<<b<<":"<<c<<d<<":"<<e<<f<<endl; for(int p=0;p<=3;p++) for(int k=2;k<=2;k++) if(b==p && a==k && c==0 && d==0 && e==0 && f==0) cout<<"\a"<<endl; } } break; default: cout<<"Error: Your ENTRY IS WRONG SIR"<<endl; } getch(); }
C Program For Creating Digital Watch
January 04, 2015
By:
Bhanu Namikaze
Bhanu Namikaze
Bhanu Namikaze is an Ethical Hacker, Security Analyst, Blogger, Web Developer and a Mechanical Engineer. He Enjoys writing articles, Blogging, Debugging Errors and Capture the Flags. Enjoy Learning; There is Nothing Like Absolute Defeat - Try and try until you Succeed.
No comments:
Post a Comment