#include <stdio.h>
#include <stdlib.h>

#define SIZE 31

int main()
{
     int array[SIZE]={0};
     int i,j;
     int startDay=0,numDays=30;
     
     printf("  S   M    T    W    TH    F    S\n");
     
     for (i=1;i<=1+ startDay*5;i++)
     printf(" ");
     
     for (i= 1; i <= numDays; i++) 
     {
               
               printf("%2d",i);
               if ((i+startDay)%7 > 0)        
                {    printf("   ");
                   system("color 6");}
                    
               else  
                    printf("\n ");
     }
     startDay = (startDay + numDays)%7;
     
     
     
            
     
     
     getchar();
     getchar();
}

I used

system("color ");

but it will only colorize my enter text...
I only want to colorize the days in Sunday;

I dont know how to do it...Can anyone teach me please?.,

but it will only colorize my enter text...

I mean "my entire text"...

don't work dude

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.