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
s2008m [1.1K]
3 years ago
6

Write a pseudocode thats accept and then find out whether the number is divisible by 5 ​

Computers and Technology
1 answer:
andreyandreev [35.5K]3 years ago
5 0

Answer:

input number

calculate modulus of the number and 5

compare outcome to 0

if 0 then output "divisible by 5"

else output "not divisible by 5"

Explanation:

The modulo operator is key here. It returns the remainder after integer division. So 8 mod 5 for example is 3, since 5x1+3 = 8. Only if the outcome is 0, you know the number you divided is a multiple of 5.

You might be interested in
3. A security system uses sensors at every door and window which will set off analarm if any one of them is opened. There is als
sp2606 [1]
A combination circuit would be needed for security because if you had a strait circuit if any one of those sensors or the keypad was ripped off the circuit will now let the flow of electricity be possible but with a combination circuit it helps eliminate that problem because even if on flow path is cut off, other paths are still available <span />
6 0
2 years ago
PLEASE HELP ME ASAP!!! Looking at the misty rain and fog (pictured above) Explain at least two defensive driving techniques you
JulsSmile [24]
1.Slow down 2. Break earlier
7 0
3 years ago
Define print_shape() to print the below shape. Example output:
ella [17]

The print_shape() is an illustration of Python function; whose execution is carried out when the function is called

<h3>The print_shape() function</h3>

The print_shape() function written in Python, where comments are used to explain each action is as follows:

#This defines the function

def print_shape():

   #The following iteration is repeated three times

   for i in range(3):

       #This prints the *** in each iteration

       print('***')

#This calls the function

print_shape()

Read more about Python functions at:

brainly.com/question/15745784

5 0
2 years ago
What CSS property do you use to determine whether flex items are displayed horizontally or vertically
Hoochie [10]

Answer:

Flex direction

Explanation:

HTML is an acronym for hypertext markup language and it is a standard programming language which is used for designing, developing and creating web pages.

Generally, all HTML documents are divided into two (2) main parts; body and head.

The head (header) contains information such as version of HTML, title of a page, metadata, link to custom favicons and cascaded style sheet (CSS) etc.

On the other hand, the body of a HTML document contains the contents or informations that a web page displays.

Generally, the part of a HTML document where the cascaded style sheet (CSS) file is linked is the header.

A style sheet can be linked to an HTML document by three (3) main methods and these are;

I. External style.

II. Inline style.

III. Embedded (internal) style.

Flex direction is a CSS property that's used to determine whether flex items are displayed horizontally or vertically.

5 0
3 years ago
Create a structure representing a student. The member variables should include student name, student ID, and four test grades fo
Neporo4naja [7]

Answer:

Output:

Name: Brainly

ID:0001

Write the 4 tests grades of the student separated by space :10 9 8 10

Brainly

0001

10 9 8 10

Average :9.66667

'1' to continue '0' to exit :

Explanation:

#include<iostream>

#include<string>

using namespace std;

//variables declaration

struct Student {

  string id; //string declaration ID

  string name; // string declaration name

  int grades[4]; //array of 4 because it is 4 grades

};

//definition of the function get information

void inputData(Student &s){

 

   

   cout << "Name:" ;

   getline(cin,s.name);

   cout << "ID:";

   cin >> s.id;

   cout << "Write the 4 tests grades of the student separated by space :";

   for (int i = 0; i<4; i++)

       cin >> s.grades[i];

}

//definition of the function of average

double inputAvg(Student s){

   double summation;

   int temporary;

   double average;

   for (int i = 0; i<4; i++){  

      for (int j = i; j<4; j++){

         if (s.grades[j] > s.grades[i]){

             temporary = s.grades[i];

             s.grades[i] = s.grades[j];

             s.grades[j] = temporary;

         }

      }

    }

    summation = 0;

    for (int i = 0; i<3; i++){

        summation = summation + s.grades[i];  

    }

    average = summation/3;

    return average;

}

void disp(Student *s){

   cout << s->name << endl;

   cout << s->id << endl;

   for (int i = 0; i<4; i++)

       cout << s->grades[i] << " ";

   cout << endl;

   cout << "Average :" << inputAvg(*s) << endl;

   

}

int main(){

  Student st;

  int ch;

  while(true){

      inputData(st);

      disp(&st);

      cout << " '1' to continue '0' to exit :";

      cin >> ch;

      if (ch == 0)

         break;      

  }

  return 0;

}

6 0
2 years ago
Other questions:
  • How many points are in an inch? <br> A 24<br> B 50<br> C 72<br> D 100
    5·1 answer
  • Play among us with me
    12·2 answers
  • The computer program that Josh is working on presents him with a sentence in which a word has been underlined. Josh has to indic
    9·1 answer
  • What might happen if the internet use policies were broken at your school
    11·2 answers
  • java Write a program that reads a list of words. Then, the program outputs those words and their frequencies. The input begins w
    11·1 answer
  • Wilma is looking for facts about social media for her research project. What fact should she use for her project?
    15·1 answer
  • Please help me I don't understand. It's Python.
    5·2 answers
  • What is keyword density?
    15·2 answers
  • How has the internet improved business communication worldwide
    11·1 answer
  • Under which menu would you be able to see the number of continuous track minutes available on each mounted hard drive at the cur
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!