#include <stdio.h>
#include <ctype.h>

// gcc49 なら bool 使えたっけ？
#define TRUE 1
#define FALSE 0

int main(void)
{
    FILE *fp = stdin;	// 手抜き
    //fp = fopen("text.txt", "r");
	int  newLineComes = TRUE;
    int c;
    printf("---ﾔﾙｾﾞ\n");
    while( (c = fgetc( fp )) != EOF ){
    	if (newLineComes) {		// 新しい行が来たぜ
    		if (islower(c)) {	// 頭文字が小文字の場合は
    			c = toupper(c);	// 大文字に変換
    		}
    		newLineComes = FALSE; // もう新しくないぜ。
    	}
    	/* 改行だけが続けて来た場合にも、「次は新しい行」と解釈すべきだから、ここに else は入れないぜ */
    	if (c == '\n') {
    		newLineComes = TRUE;	// 次は新しい行が来るぜ
    	}
        printf( "%c", c );
    }
    printf("---ｵﾜﾀ\n");
    fclose(fp);
    return 0;
}
