結果

問題 No.1943 消えたAGCT(1)
ユーザー nyst
提出日時 2022-05-20 21:56:31
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
WA  
実行時間 -
コード長 452 bytes
コンパイル時間 832 ms
コンパイル使用メモリ 93,508 KB
実行使用メモリ 6,944 KB
最終ジャッジ日時 2024-09-20 08:01:33
合計ジャッジ時間 1,741 ms
ジャッジサーバーID
(参考情報)
judge3 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 25 WA * 2
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <algorithm>
#include <vector>
#include <string>
#include <map>
#include <set>
#include <fstream>
#include <cmath>
#include <stack>
#include <queue>
#include <iomanip>
using namespace std;

int main(){
  int n;cin>>n;
  string s;cin>>s;

  int index = 0;
  for(int i=0;i<n;i++){
    if(s[i]=='A' || s[i]=='G' || s[i]=='C' || s[i]=='T') index = i;
  }
  if(index==0) cout << index << endl;
  else cout << index + 1 << endl;
}
0