use std::io::Read;

fn main() {
	let mut s = String::new();
	std::io::stdin().read_to_string(&mut s).ok();
	let n: Vec<u64> =
		s.split_whitespace().skip(1).flat_map(str::parse).collect();
	for n in n {
		let mut x = (n as f64).sqrt().ceil() as u64;
		while x * x > n {
			x -= 1;
		}
		println!("{x}")
	}
}