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
Anna [14]
3 years ago
10

Why are people getin mad at me for anserin a question ?

Computers and Technology
1 answer:
Usimov [2.4K]3 years ago
6 0
Maybe because you didn’t give them the correct answer
You might be interested in
The length of a hailstone sequence is the number of terms it contains. For example, the hailstone sequence in example 1 (5, 16,
11111nata11111 [884]

Answer:

Following are the program to this question:

#include <iostream> //defining header file

using namespace std;

int hailstoneLength(int n) //defining method hailstoneLength

{

int t=1; //defining integer variable assign  

while(n!=1) //define a loop that checks value is not equal to 1

{

if(n%2==0) // check even number condition

{

n=n/2; // divide the value by 2 and store its remainder value in n

t++; //increment value of t by 1.

}

else

{

n=n*3+1; //calculate and hold value in n  

t++; //increment value of t variable by 1  

}

}

return t; //return value

}

int main() //defining main method

{

int n; //defining integer variable

cout<<"Enter any number: "; //print message

cin>> n; //input value

cout<<hailstoneLength(n); //call method and print its value

return 0;

}

Output:

Enter any number: 3

8

Explanation:

Program description can be given as follows:

  • In the given C++ language program an integer method "hailstoneLength", is declared, that accepts an integer variable "n" in its parameter.
  • Inside the method, an integer variable t is declared, that assign a value that is 1, in the next line, a while loop is declared, that uses if block to check even condition if number is even it divide by 2 and increment t variable value by 1.
  • If the number is odd it will multiply the value by 3 and add 1 and increment t by 1 then it will go to if block to check value again. when value of n is not equal to 1 it will return t variable value.
  • In the main method, an integer variable "n" is used that call the method and print its return value.
7 0
3 years ago
Dell Computer purchases parts and resources for its computers from multiple suppliers that are spread across the world. This pra
givi [52]
The correct answer is outsourcing
6 0
3 years ago
What may happen if a large number of computer users are attempting to access a web site at the same time that you are
Nitella [24]
It will most likely begin to crash and eventually just freeze , i'm guessing  
6 0
3 years ago
Read 2 more answers
Consider the recursive method myprint in this code snippet: public void myprint(int n) { if (n &lt; 10) { system.out.print(n); }
valkas [14]
What the method does, is it takes the rightmost decade and prints it, then divides by 10 and repeats. Effectively this means the number is printed backwards, so the output is 128.
7 0
3 years ago
Which of the following function declarations correctly expect an array as the first argument?
NARA [144]

Answer:

Only

Option: void f1(float array[], int size);

is valid.

Explanation:

To pass an array as argument in a function, the syntax should be as follows:

functionName (type arrayName[ ] )

We can't place the size of the array inside the array bracket (arrayName[100]) as this will give a syntax error. The empty bracket [] is required to tell the program that the value that passed as the argument is an array and differentiate it from other type of value.

3 0
3 years ago
Other questions:
  • Which of the following situations would not require knowledge of networking?
    6·1 answer
  • A power supply unit for a computer converts:
    7·1 answer
  • When using query by example (qbe) in the data manipulation component of a database management system (dbms), the _____ is used w
    5·1 answer
  • What are the different nail disorders?
    13·1 answer
  • Public class Square extends Shape{
    13·1 answer
  • Write a couple of paragraphs about the usefulness of computer​
    5·1 answer
  • Please answer it’s timed
    11·1 answer
  • Write the importance of program in computer​
    9·1 answer
  • Hi am feeling really happy just passed a test after a lot of tries :-)
    5·1 answer
  • This method of file transfer has been used for decades and is frequently used for uploading changes to a website hosted by an in
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!