結果
問題 | No.175 simpleDNA |
ユーザー |
|
提出日時 | 2016-11-30 16:48:08 |
言語 | C90 (gcc 12.3.0) |
結果 |
AC
|
実行時間 | 1 ms / 1,000 ms |
コード長 | 242 bytes |
コンパイル時間 | 94 ms |
コンパイル使用メモリ | 20,608 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-11-27 14:00:12 |
合計ジャッジ時間 | 576 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 6 |
コンパイルメッセージ
main.c: In function ‘main’: main.c:12:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 12 | scanf("%d%d",&l,&n); | ^~~~~~~~~~~~~~~~~~~ main.c:13:31: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 13 | for(i = 1;i <= n;i++){scanf("%s",s);} | ^~~~~~~~~~~~~
ソースコード
#include <stdio.h>int p2(int x){int i,r=1;for(i = 1;i <= x;i++){r*=2;}return r;}int main(void) {int l,n,i,r;char s[4];scanf("%d%d",&l,&n);for(i = 1;i <= n;i++){scanf("%s",s);}r = p2(l-3);printf("%d\n",r*n);return 0;}