Answer:
// Program is written in Java Programming Language
// Comments are used for explanatory purpose
import java.util.*;
public class FlipCoin
{
public static void main(String[] args)
{
// Declare Scanner
Scanner input = new Scanner (System.in);
int flips;
// Prompt to enter number of toss or flips
System.out.print("Number of Flips: ");
flips = input.nextInt();
if (flips > 0)
{
HeadsOrTails();
}
}
}
public static String HeadsOrTails(Random rand)
{
// Simulate the coin tosses.
for (int count = 0; count < flips; count++)
{
rand = new Random();
if (rand.nextInt(2) == 0) {
System.out.println("Tails"); }
else {
System.out.println("Heads"); }
rand = 0;
}
}
Its safe because it isn't something with electricity
Answer:
The constant here is the study outline
Explanation:
In scientific research, the constant variable is that part/variable of the experiment that does not change or is set not to change. Examples include temperature, environment or height.
Assuming the scenery described in this question is an experiment. All the groups presented are bound by a constant during the experiment. The constant here is the study outline. The study outline provided to the students is not going to change.
NOTE: There could be confusion as regards the answer being the final exam grade but that will be the dependent variable as that will be the outcome of the experiment while the time spent to study will be the independent variable.