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
ser-zykov [4K]
2 years ago
12

Write a program that simulates applying a "boost" to a spaceship in a spaceship race game.

Computers and Technology
1 answer:
rewona [7]2 years ago
8 0

Programming languages can be used to simulate several scenarios; in this case, the "boost"

The simulating program in C++ where comments are used to explain each line is as follows:

#include<iostream>

#include<cstdlib>

#include<ctime>

using namespace std;

int main() {

 // This sets the seed to time(0)

 srand(time(0));

 // This generates a random number between 0 and 10, to represent the boost

 int boost = rand()%10;

 // This prints the required outputs

 cout << "Boost: " << boost;

 cout << "\nDistance travelled: " << boost;

 return 0;

}

Read more about similar programs at:

brainly.com/question/16240699

You might be interested in
What does l m a o actually mean?
vladimir2022 [97]

Answer:

L-Laughing m-my a-a*s o-off

Explanation:

8 0
3 years ago
Does the brain play a role in smartphone addiction
Fynjy0 [20]
Attractive Google search and browse website . playing video games smartphone addiction
7 0
3 years ago
Read 2 more answers
What does a student use when types text into a word processing program ?
kozerog [31]

Answer:

Computer Software

Explanation:

Computer software; s a set of instructions that tells a computer what to do or how to perform a task.

6 0
3 years ago
Most shops require the technician to enter a starting and ending time on the repair order to track the actual time the vehicle w
Alecsey [184]

The time being referred to is C. cycle time. Cycle time refers to the amount of time from start to end of a process as agreed and defined by a service provider (in this case, the technician) and the customer. Cycle time can also be lengthened or shortened.

5 0
4 years ago
Read 2 more answers
A network technician attempts to ping www.example.net from a customer computer, but the ping fails. access to mapped network dri
S_A_V [24]

It appears that the local network connection (ethernet, Wi-Fi, etc.) is working but the gateway to the WAN is down.

8 0
3 years ago
Other questions:
  • The network layer, or osi layer 3, provides services to allow end devices to exchange data across the network. to accomplish thi
    15·1 answer
  • Gn to be printed at a commercial printer. Which main ink type's exact color appearance is determined by the printer and requires
    13·1 answer
  • A game’s ______ is what contains its directions and calculations; some refer to it as the “engine” that drives the game.
    12·1 answer
  • Two of the goals of community mobilization are getting the community interested and
    6·1 answer
  • A professional bureaucracy is a knowledge-based organization where goods and services depend on the expertise and knowledge of p
    7·1 answer
  • Consider the following code segment:
    8·1 answer
  • Write an essay about yourself based on the dimensions of ones personality​
    9·1 answer
  • Match the roles to the task they perform.
    5·1 answer
  • PLSS HELP ASAP ILL GIVE BRAINLIEST THANKS
    15·2 answers
  • Some elementary particles are positively or negatively
    11·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!