计算输入a和b的几何平均值。两个数字的几何平均值是a * b的平方根。
import java.util.*;
import java.io.*;
import java.math.*;
/**
* Auto-generated code below aims at helping you parse
* the standard input according to the problem statement.
**/
class Solution {
public static void main(String args[]) {
Scanner in = new Scanner(System.in);
int a = in.nextInt();
int b = in.nextInt();
// Write an answer using System.out.println()
// To debug: System.err.println("Debug messages...");
System.out.println((int)Math.sqrt(a*b));
}
}
- geometric mean Calculate the ofgeometric mean calculate the state-of-the-art name-of-the-rose-and-dayflower the_counterintuitive_art_of_memor fear dark the of shellcode the art of python the zen of eating game the of the_counterintuitive_art_of_memor why_retrieval_beats_cramming_ name-of-the-rose-and-dayflower dayflower name