結果

問題 No.2049 POP
ユーザー ixTL255ixTL255
提出日時 2022-12-27 23:49:58
言語 Rust
(1.77.0)
結果
WA  
実行時間 -
コード長 231 bytes
コンパイル時間 1,369 ms
コンパイル使用メモリ 138,468 KB
実行使用メモリ 4,388 KB
最終ジャッジ日時 2023-08-14 13:36:41
合計ジャッジ時間 2,182 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
testcase_08 WA -
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
権限があれば一括ダウンロードができます
コンパイルメッセージ
warning: unused return value of `core::str::<impl str>::trim` that must be used
 --> Main.rs:9:2
  |
9 |     s.trim();
  |     ^^^^^^^^
  |
  = note: this returns the trimmed string as a slice, without modifying the original
  = note: `#[warn(unused_must_use)]` on by default

warning: 1 warning emitted

ソースコード

diff #

use std::io;

fn main() {
	let mut n: String = String::new();
	let mut s: String = String::new();
	io::stdin().read_line(&mut n).ok();
	io::stdin().read_line(&mut s).ok();
	
	s.trim();
	s.remove(0);
	s.pop();

	println!("{}", s);
}
0