Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
Tech No.
//'main' method must be in a class 'Rextester'. //Compiler version 1.8.0_111 import java.util.*; import java.lang.*; class Rextester { public static void main(String args[]) { Scanner Sc=new Scanner(System.in); System.out.println("enter a no"); int n = Sc.nextInt(); int i,d,c=0,p,s,r; for (i=n;i>0;i=i/10) // error tha { c++; } if(c%2!=0) System.out.println("invalid no"); else { d=(int)Math.pow(10,c/2); p=n%d; r=n/d; s=p+r; if(s*s==n) // error tha System.out.println("yes"+n); else System.out.println("no"+n); } } }
run
|
edit
|
history
|
help
0
boolean1
Java Constructors
do while
updated
Basic Matrix
Fibonacci number 0 - 93
This code is not what it seems...
java
상속2
dimond of stars