Project Name:
Digital Clock
 Group Members:
 Abdul Waheed 16-Arid-5255
 Muhammad Moin 16-Arid-5284
 Muhammad Mohsan 16-Arid-5283
 Sarfraz Ahmed 16-Arid-5294
Class:
BS-Computer Science-II
Project Proposal
Project Proposal
Introduction:
A digital clock is a type of clock that displays the time digitally in numerals. This
program will generate a digital clock using c program.
The logic behind to implement this program :
 Initialize hour, minute, seconds with 0 using structure.
 Run an infinite loop.
 Increase second and check if it is equal to 60 then increase minute and reset second to 0.
 Increase minute and check if it is equal to 60 then increase hour and reset minute to 0.
 Increase hour and check if it is equal to 24 then reset hour to 0.
Objectives & Scope:
 7-Seg to be display.
 24-hour time roll over.
 May be A.M,P.M(12-hour roll over).
Technology used:
C++
Tool:
Dev-C++ version 5.11
Project Proposal
Digital Clock Coding:
1st Step ; Using structure
struct time
{
int hr,min,sec;
};
2nd Step ; Variable Declaration
int main()
{
time a;
a.hr = 0;
a.min = 0;
a.sec = 0;
Project Proposal
3rd Step : Using for Loop& IF Statment
for(int i = 0; i<24; i++)
{
if(a.hr == 23)
{
a.hr = 0;
}
for(int j = 0; j<60; j++)
{
if(a.min == 59)
{
a.min = 0;
}
for(int k = 0; k<60; k++)
{
if(a.sec == 59)
{
a.sec = 0;
}
cout<<a.hr<<" : "<<a.min<<" : "<<a.sec<<endl;
a.sec++;
}
a.min++;
}
a.hr++;
}
}
Project Proposal
Currently Output:
Project Proposal
Submitted by:
Miss Shumaila
 Most incredible Mam in my study life
 Thanks for taking our Programming class.
 You have a great experience of donating knowledge to the students.
 We love your attitude.
Thank you mam Shumaila for improving
our way of representing.
Project Proposal

Proposal for project ofdigital class in C++

  • 1.
    Project Name: Digital Clock Group Members:  Abdul Waheed 16-Arid-5255  Muhammad Moin 16-Arid-5284  Muhammad Mohsan 16-Arid-5283  Sarfraz Ahmed 16-Arid-5294 Class: BS-Computer Science-II Project Proposal
  • 2.
    Project Proposal Introduction: A digitalclock is a type of clock that displays the time digitally in numerals. This program will generate a digital clock using c program. The logic behind to implement this program :  Initialize hour, minute, seconds with 0 using structure.  Run an infinite loop.  Increase second and check if it is equal to 60 then increase minute and reset second to 0.  Increase minute and check if it is equal to 60 then increase hour and reset minute to 0.  Increase hour and check if it is equal to 24 then reset hour to 0. Objectives & Scope:  7-Seg to be display.  24-hour time roll over.  May be A.M,P.M(12-hour roll over). Technology used: C++ Tool: Dev-C++ version 5.11
  • 3.
    Project Proposal Digital ClockCoding: 1st Step ; Using structure struct time { int hr,min,sec; }; 2nd Step ; Variable Declaration int main() { time a; a.hr = 0; a.min = 0; a.sec = 0;
  • 4.
    Project Proposal 3rd Step: Using for Loop& IF Statment for(int i = 0; i<24; i++) { if(a.hr == 23) { a.hr = 0; } for(int j = 0; j<60; j++) { if(a.min == 59) { a.min = 0; } for(int k = 0; k<60; k++) { if(a.sec == 59) { a.sec = 0; } cout<<a.hr<<" : "<<a.min<<" : "<<a.sec<<endl; a.sec++; } a.min++; } a.hr++; } }
  • 5.
  • 6.
    Project Proposal Submitted by: MissShumaila  Most incredible Mam in my study life  Thanks for taking our Programming class.  You have a great experience of donating knowledge to the students.  We love your attitude. Thank you mam Shumaila for improving our way of representing.
  • 7.