+ 7
47 chrs, based on @Ace's code.
https://code.sololearn.com/cYt5wCoPolaG/?ref=app
2nd one (54 chrs)
https://code.sololearn.com/c7kZVzcmnhsK/?ref=app
3rd one with input (60 chrs)
https://code.sololearn.com/ceqeRBtGudMi/?ref=app
+ 17
+ 14
Nice challenge but I found my C# approach is very similar to most implementations here after finished the code and I believe Python or Ruby can do it much better. Anyway here you go:
https://code.sololearn.com/cZo4V24ERPS8/?ref=app
+ 12
2 line code with checking the correct user input...
https://code.sololearn.com/ctEoT725FyrW/#java
+ 10
https://code.sololearn.com/cPhvh3nRvOgs/?ref=app
+ 9
here is my try:-
https://code.sololearn.com/coEeol0fcubY/?ref=app
+ 9
my practice on python https://code.sololearn.com/cTDyHuAw5Cel/#py :)
+ 8
Number.prototype.rip = function() {
var a = this+''.split('');
var n = Number(a[0]+a[1]) + Number(a[2]+a[3]);
return this==n*n?true:false;
}
https://code.sololearn.com/WhAIwCuYAmyo/?ref=app
+ 7
I can't part Python :(
https://code.sololearn.com/c7jRunF3CFL1/?ref=app
+ 6
I made too much Python codes.
Gotta do it in a new language
+ 6
125 characters amazing Karthikey?
+ 6
ok guys .... less than 70 characters :-))
including a kind of readable answer
(thanks to pre-work of the challenger)
https://code.sololearn.com/cpkf7jHGXfNG
+ 6
Second attempt
8 lines only
https://code.sololearn.com/cEM6CzD8a9Ik/?ref=app
+ 5
I updated code, thanka for reminding Ace
+ 5
@Ven It will be more shorter than you if I remove 2nd line
+ 5
Lol mine is 121 characters perfectly 11^2 lol
+ 5
@Ekansh You have to take input from user and check if it is b/w 1000 and 9999( including)
+ 5
@Kartikey but it's not specified in the Challenge.
+ 5
My rushed attempt in java
https://code.sololearn.com/cn6IyVgTGU0t/?ref=app
+ 4
Mine is perfect too, 5^3