結果
| 問題 | No.163 cAPSlOCK |
| コンテスト | |
| ユーザー |
kachipan
|
| 提出日時 | 2023-06-23 10:58:41 |
| 言語 | C(gnu17) (gcc 15.2.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 5,000 ms |
| コード長 | 389 bytes |
| 記録 | |
| コンパイル時間 | 192 ms |
| コンパイル使用メモリ | 37,984 KB |
| 最終ジャッジ日時 | 2026-02-22 10:55:05 |
|
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 20 |
ソースコード
#include <stdio.h>
#include <stdlib.h>
#include <stdbool.h>
int main()
{
char str[101] = "";
scanf("%s", &str, sizeof(str));
for (int i = 0;str[i] != '\0';i++)
{
int smallLast = 'z';
int bigLast = 'Z';
if (str[i] <= smallLast && str[i] > bigLast)
{
str[i] -= smallLast - bigLast;
}
else
{
str[i] += smallLast - bigLast;
}
}
printf("%s", str);
return 0;
}
kachipan