How to Reverse a Number in Java
The challenge
Given a number, write a function to output its reverse digits. (e.g. given 123 the answer is 321)
Numbers should preserve their sign; …
Read Article →342 articles about java development, tools, and best practices
Given a number, write a function to output its reverse digits. (e.g. given 123 the answer is 321)
Numbers should preserve their sign; …
Read Article →Suppose you have 4 numbers: '0', '9', '6', '4'
and 3 strings composed with them:
s1 = "6900690040"
s2 = "4690606946"
s3 …
Read Article →
What date corresponds to the n
th day of the year?
The answer depends on whether the year is a leap year or not.
Write a function that …
Read Article →You probably know that some characters written on a piece of paper, after turning this sheet 180 degrees, can be read, although …
Read Article →Make two functions, max
and min
that take a(n) array/vector of integers list
as input and outputs, respectively, the largest and lowest …
Write a function that takes a string of parentheses, and determines if the order of the parentheses is valid. The function should return …
Read Article →Write a function that determines whether a string is a valid guess in a Boggle board, as per the rules of Boggle. A Boggle board is a 2D …
Read Article →Write a function that reverses the bits in an integer.
For example, the number 417
is 110100001
in binary. Reversing the binary is …
You have created a ./target/.jar and have tried to run it using java -jar <app>.jar
yet receive a spring boot no main manifest attribute, in …
!-->
Write a function that accepts two square matrices (N x N
two dimensional arrays), and return the sum of the two. Both matrices being …
The number 81 has a special property, a certain power of the sum of its digits is equal to 81 (nine squared). Eighty one (81), is the …
Read Article →