All I need is a screen shot of the output of this program

Discussion in 'C++' started by rowley4, Aug 30, 2010.

  1. rowley4

    rowley4 New Member

    Joined:
    Aug 30, 2010
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    0
    Can someone please compile this program and send me the screen shot of the output of this program? I can not compile on the current computer I am on, and all I need is the output screen shot. Thank you so much! It is an analog clock program.

    Code:
    int main()
    {
    struct time *t1;      
    int gdriver =DETECT,gmode;
    initgraph(&gdriver,&gmode,"");
    while(1)
    {
    gettime(t1); 
    circle(300,150,100); 
    printf("The current time is: %2d:%02d:%02d.%02d\n", t1->ti_hour,t1->ti_min,t1->ti_sec); 
    if ( (t1->ti_hour) >12) {t1->ti_hour=t1->ti_hour-12;} 
    setfillstyle(1,BLUE);
    pieslice(300,150,(360-(t1->ti_hour*30))+90,(360-(t1->ti_hour*30))+95,40);
    setfillstyle(1,RED);
    pieslice(300,150,360-(t1->ti_min *6)+90,360-(t1->ti_min*6)+95,80);
    pieslice(300,150,360-(t1->ti_sec *6)+90,360-(t1->ti_sec*6)+91,90);
    sleep(1);
    }
    getch();
    closegraph();
    return 0; 
    }
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice