본문 바로가기

백준 문제풀기/JAVA

[백준 24266 JAVA 자바] 알고리즘 수업 - 알고리즘의 수행 시간 5

 

3중 for문입니다

지금까지 하던대로 하면 됩니다

 

코드입니다

import java.util.Scanner;

public class Main {
	
	static int count = 0;
	
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		Long n = scan.nextLong();
		
		Long t = n*n*n;
		
		System.out.println(t+"\n"+3);
	}
}