結果
| 問題 | No.1264 010 |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2026-10-14 22:12:19 |
| 言語 | Rust (1.99.0 + proconio + num + itertools + ACL) |
| 結果 |
AC
不安定
|
| 実行時間 | 1 ms / 1,000 ms |
| + 58µs | |
| コード長 | 392 bytes |
| 記録 | |
| コンパイル時間 | 924 ms |
| コンパイル使用メモリ | 177,140 KB |
| 実行使用メモリ | 9,828 KB |
| 最終ジャッジ日時 | 2026-10-14 22:12:37 |
| 合計ジャッジ時間 | 2,121 ms |
|
ジャッジサーバーID (参考情報) |
judge6_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 9 |
コンパイルメッセージ
warning: unused import: `std::collections::HashMap`
--> src/main.rs:2:5
|
2 | use std::collections::HashMap;
| ^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default
warning: unused import: `std::collections::BTreeSet`
--> src/main.rs:3:5
|
3 | use std::collections::BTreeSet;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
warning: unnecessary parentheses around `for` iterator expression
--> src/main.rs:14:18
|
14 | for i in (0..n){
| ^ ^
|
= note: `#[warn(unused_parens)]` (part of `#[warn(unused)]`) on by default
help: remove these parentheses
|
14 - for i in (0..n){
14 + for i in 0..n {
|
warning: variable does not need to be mutable
--> src/main.rs:13:13
|
13 | let mut c=0;
| ----^
| |
| help: remove this `mut`
|
= note: `#[warn(unused_mut)]` (part of `#[warn(unused)]`) on by default
warning: unused variable: `c`
--> src/main.rs:13:13
|
13 | let mut c=0;
| ^^^^^ help: if this is intentional, prefix it with an underscore: `_c`
|
= note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default
warning: unused variable: `i`
--> src/main.rs:14:13
|
14 | for i in (0..n){
| ^ help: if this is intentional, prefix it with an underscore: `_i`
ソースコード
use proconio::input;
use std::collections::HashMap;
use std::collections::BTreeSet;
fn main(){
input!{
mut n:usize,
}
if n==0{
print!("{}",1);
} else {
let mut vec=vec!['0','1','0'];
n-=1;
let mut c=0;
for i in (0..n){
vec.push('0');
}
for i in vec{
print!("{}",i);
}
}
}