1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Triss [41]
2 years ago
6

Write code that prints: Ready! userNum ... 2 1 Go! Your code should contain a for loop. Print a newline after each number and af

ter each line of text. Ex: If the input is: 3 the output is: Ready! 3 2 1 Go!
Computers and Technology
1 answer:
Vinvika [58]2 years ago
8 0

Answer:

Kindly find the code snippet in the explanation written in kotlin language

Explanation:

fun main(args: Array<String>) {

   var num:Int

   println("Enter a num")

    num= Integer.valueOf(readLine())

   for(i in num downTo 1){

       if(i==num){

           print("Ready!")

           print(" ")

       }

       print(i)

       print(" ")

       if(i==1){

           print(" ")

           print("Go!")

       }

   }

}

This function too can also work

fun numTo(num:Int){

   if (num>0) for(i in num downTo 1) print("$i ")

   println("Go!")

You might be interested in
You can use this type of program to create a new raster image
butalik [34]

Answer:

yes

Explanation:

8 0
3 years ago
A static class method can be accessed without referring to any objects of the class. True False
VLD [36.1K]

Answer:

True

Explanation:

This is true because a static class method can be accessed without referring to any objects of the class. When a class member is made static, it's very easy to access the object.

The member becomes static and becomes class level

4 0
3 years ago
Could anyone help me with this assignment please?
kicyunya [14]

Answer:

"Word Processing Assignment

5 0
2 years ago
There is a group of 10 people who are ordering pizza. If each person gets 2 slices and each pizza has 5 slices, how many pizzas
Brums [2.3K]

Answer: they should get 4 pizzas

Explanation:

you times 10 by 2 which equals 20 then divide by 5 which equals 4

7 0
2 years ago
Question 16 (2 points) Question 16 Unsaved
strojnjashka [21]
I will help with as many as I can! :)
-
16. Slogans
17. Website Design and Development Process
18. Planning
19. (This question is the same as question 18 so I am at a loss here, sorry)
20. Confuse users, believing it is a hyperlink.

I apologize for the wait. I was trying to double check my sources. Also, I apologize in advance if something is wrong.
3 0
3 years ago
Other questions:
  • Heatsinks used to protect cpus in computers from overheating, are shaped so that their surface area is very large. why is that?
    5·1 answer
  • The operating system of a computer is an example of ________ software. science-forum
    7·1 answer
  • vulnerability is a feebleness which allows an attacker to condense a system's information assurance to security,is it true or fa
    14·1 answer
  • You run the ipconfig command on your computer, and it reports an IP address of 169.254.75.10 on the Ethernet interface. Which de
    8·1 answer
  • When does a soft page break occur in a document
    9·1 answer
  • Why is simplicity important in navigation design?
    13·1 answer
  • Write a method, findMax(), that takes in two integers and returns the largest value. Ex: If the program input is: 4 2 the method
    8·1 answer
  • Miley met up with a bunch of her college friends after several years. She told them that she works for the sound department of a
    5·1 answer
  • What is the full form of the OS?​
    15·2 answers
  • Write a program that simulates applying a "boost" to a spaceship in a spaceship race game.
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!