AOJ803魔方
来源:互联网 发布:c语言中的float 编辑:程序博客网 时间:2024/05/20 18:47
package contest;import java.util.Scanner;public class Main{ public static void main(String[] args) { Scanner sc=new Scanner(System.in); while(sc.hasNextInt()){ int a=sc.nextInt(); if(a==1){ System.out.println(1); }else{ System.out.println(a*a*a-(a-2)*(a-2)*(a-2)); } } }}
0 0