結果
問題 | No.175 simpleDNA |
ユーザー |
![]() |
提出日時 | 2025-03-26 11:46:40 |
言語 | C (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 1 ms / 1,000 ms |
コード長 | 309 bytes |
コンパイル時間 | 488 ms |
コンパイル使用メモリ | 24,960 KB |
実行使用メモリ | 7,324 KB |
最終ジャッジ日時 | 2025-03-26 11:46:41 |
合計ジャッジ時間 | 1,452 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 6 |
コンパイルメッセージ
main.c: In function ‘main’: main.c:5:5: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 5 | scanf("%d\n",&l); | ^~~~~~~~~~~~~~~~ main.c:7:5: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 7 | scanf("%d\n",&n); | ^~~~~~~~~~~~~~~~ main.c:10:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 10 | scanf("%s",list); | ^~~~~~~~~~~~~~~~
ソースコード
#include <stdio.h> void main(void){ int l = 0; scanf("%d\n",&l); int n = 0; scanf("%d\n",&n); char list[10] = "a"; for(int i = 0; i < n ; i++){ scanf("%s",list); } int count = 1; for(int i = 0 ; i < l-3 ; i++){ count *= 2; } printf("%d",count*n); }