結果

問題 No.381 名声値を稼ごう Extra
コンテスト
ユーザー uretihsiaania
提出日時 2023-11-09 18:10:08
言語 Rust
(1.94.0 + proconio + num + itertools)
コンパイル:
/usr/bin/rustc_custom
実行:
./target/release/main
結果
AC  
実行時間 1,016 ms / 8,000 ms
コード長 2,621 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 1,617 ms
コンパイル使用メモリ 187,136 KB
実行使用メモリ 6,400 KB
最終ジャッジ日時 2026-04-13 03:11:48
合計ジャッジ時間 3,672 ms
ジャッジサーバーID
(参考情報)
judge3_0 / judge1_0
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 2
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

#![allow(unused_imports)]

// use ac_library::{
//     pow_mod, Dsu, FenwickTree, ModInt, ModInt1000000007, ModInt998244353, Segtree, StaticModInt,
// };
// use amplify::{
//     list,
//     num::{i1024, i256, i512, u1024, u256, u512},
// };
// use argio::argio;
// use ascii::{AsciiChar, AsciiString};
// use btreemultimap::{btreemultimap, BTreeMultiMap};
// use counter::Counter;
// use either::Either;
// use fixedbitset::FixedBitSet;
// use hashbag::HashBag;
// use indexmap::{indexmap, indexset, IndexMap, IndexSet};
// use itertools::Itertools;
// use itertools_num::ItertoolsNum;
// use maplit::{btreemap, btreeset, hashmap, hashset};
// use memoise::memoise_map;
// use multimap::{multimap, MultiMap};
use num::{
    abs, clamp,
    integer::{binomial, gcd, lcm, Roots},
    range_step, range_step_inclusive,
    rational::Ratio,
    traits::Pow,
    BigInt, BigRational, BigUint, Complex, Float, FromPrimitive, Integer, Num, One, PrimInt,
    Rational64, ToPrimitive,
};
// use once_cell::sync::Lazy;
// use pathfinding::prelude::{
//     bfs, bfs_reach, components, dfs, dfs_reach, dijkstra as pathdijkstra, topological_sort, Grid,
// };
// use petgraph::{
//     algo::{
//         connected_components, dijkstra, is_bipartite_undirected, is_cyclic_directed,
//         is_cyclic_undirected, min_spanning_tree, toposort,
//     },
//     graph::{DiGraph, EdgeIndex, NodeIndex, UnGraph},
//     unionfind::UnionFind,
//     visit::{depth_first_search, Bfs, Dfs},
// };
use proconio::{
    input,
    // marker::{Bytes, Chars, Usize1},
    // source::line::LineSource,
};
// use rand::Rng;
// use recur_fn::{recur_fn, RecurFn};
// use regex::Regex;
// use rustc_hash::{FxHashMap, FxHashSet, FxHasher};
// use smallvec::SmallVec;
// use std::{
//     cell::OnceCell,
//     cmp::{max, min, Ordering, Reverse},
//     collections::{BTreeMap, BTreeSet, BinaryHeap, HashMap, HashSet, LinkedList, VecDeque},
//     io::{stdin, BufReader},
//     iter::zip,
//     mem::swap,
//     process, vec,
// };
// use superslice::Ext;
// use text_io::read;
// use varisat::{CnfFormula, ExtendFormula, Lit, Solver, Var};

// #[allow(dead_code)]
// type FxHashBag<T> = HashBag<T, std::hash::BuildHasherDefault<FxHasher>>;
// #[allow(dead_code)]
// type FxIndexMap<K, V> = IndexMap<K, V, std::hash::BuildHasherDefault<FxHasher>>;
// #[allow(dead_code)]
// type FxIndexSet<T> = IndexSet<T, std::hash::BuildHasherDefault<FxHasher>>;
// #[allow(dead_code)]
// type FxMultiMap<K, V> = MultiMap<K, V, std::hash::BuildHasherDefault<FxHasher>>;

fn main() {
    input! {
        n: BigUint,
    }
    println!("{}", n.count_ones());
}
0