結果

問題 No.1943 消えたAGCT(1)
ユーザー umezo
提出日時 2022-05-20 22:09:20
言語 C++17
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 6 ms / 2,000 ms
コード長 397 bytes
コンパイル時間 2,080 ms
コンパイル使用メモリ 192,520 KB
最終ジャッジ日時 2025-01-29 10:44:44
ジャッジサーバーID
(参考情報)
judge3 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 27
権限があれば一括ダウンロードができます

ソースコード

diff #

#define rep(i,n) for(int i=0;i<(int)(n);i++)
#define ALL(v) v.begin(),v.end()
typedef long long ll;
 
#include<bits/stdc++.h>
using namespace std;
 
int main(){
  ios::sync_with_stdio(false);
  std::cin.tie(nullptr);

  int n;
  string s;
  cin>>n>>s;
  int num=-1;
  rep(i,n){
    if(s[i]=='A' || s[i]=='G' || s[i]=='C' || s[i]=='T') num=i;
  }
  cout<<num+1<<endl;
  
  
  
  
    
  return 0;
}
0