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
Day 1
Кошачья бойня
Multiplying Two Base-36 Numbers
Granite Java
rta
assigment java programming
Test processing time (loop vs. contains)
1*2-3+4
hextoepeen
currency.java