結果
| 問題 | No.224 文字列変更(easy) |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2017-10-14 01:43:37 |
| 言語 | C++11 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 201 bytes |
| 記録 | |
| コンパイル時間 | 661 ms |
| コンパイル使用メモリ | 76,036 KB |
| 実行使用メモリ | 7,976 KB |
| 最終ジャッジ日時 | 2026-05-12 09:15:15 |
| 合計ジャッジ時間 | 2,697 ms |
|
ジャッジサーバーID (参考情報) |
tmp-judge_1 / judge3_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 1 WA * 21 |
コンパイルメッセージ
main.cpp: In function 'int main()':
main.cpp:9:26: warning: 'n' is used uninitialized [-Wuninitialized]
9 | for(int i = 0; i < n; i++){
| ~~^~~
main.cpp:6:13: note: 'n' was declared here
6 | int n;
| ^
ソースコード
#include <iostream>
#include <algorithm>
using namespace std;
int main(){
int n;
string S, T;
int ans = 0;
for(int i = 0; i < n; i++){
if(S[i] != T[i]){
ans++;
}
}
cout << ans << endl;
}