Hello, can someone please tell me how this code should be?
It has to be coded in java

1. Ask the user to input a number of type double which you will find the square root of the number.

2. Create a method called rootPositive which will either print the square root of the number passed to it or if the number is less than zero, it will print out the statement "Number must not be negative.".

3. Call your rootPositive method and pass to it the number the user enetered.

thank you