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
patriot [66]
3 years ago
5

Write a program to display the roll number of students who have scored 100 in math. display appropriate message if none have sco

red 100 in math. assume 10 array elements. (Blue J)
Computers and Technology
1 answer:
SVEN [57.7K]3 years ago
5 0

Answer:

# include<iostream>

#include<conio.h>

using namespace std;

main()

{

int mathmarks[10];

int highestmarks = 100;

int check =0;

for(int i= 1; i<=10; i++)

{

cout<<"\nMarks of student "<<i<<"in maths =";

cin>>mathmarks[i];

}

for (int j= 1 ; j<=10; j++)

{

    if (mathmarks[j] == highestmarks)

    {

    check = 1;

    break;

    }

}

if (check = 1)

{

cout<<"The student having 100 marks in class having roll # ="<<j;

}

else

{

cout<<"No Student Have 100 Marks in Class";

}

getch();

}

Explanation:

In this program, we need to find the student who have got 100 marks and print his roll number. if no students have 100 marks then print "No students got 100 marks in class". So, we take and integer type array named mathmarks of size 10. Two integer variables named highestmarks to store 100 and check to check the condition in if else. Initially check = 0, if we found the student having 100 marks then this will be updated as 1 and we print our required output, else we print no student got 100 marks.

You might be interested in
Why do primitive types have ranges of values? what determines the range of the data type?
Alexxx [7]
What determines the range of primitive data types is a combination of the number of bytes that is allocated to them and if there's any encoding.

Not too long ago, it was normal for an integer to receive four bytes of memory. An unsigned integer would also receive four bytes of memory. The unsigned int  had a range of 0 - (2^32 - 1) because it could only be used for positive integers and could use all 32 bits. An integer has a range of (- 2^31 through +2^31 - 1). The 32nd bit is uses as a sign bit (0 for positive, 1 for negative).

Just for thoroughness: when an int is negative, it's stored as the two's complement of it's absolute value.
5 0
3 years ago
You have been asked to troubleshoot a legacy system running a critical component on your employer's network. Initial findings in
timurjin [86]

Answer:

HDB

Explanation:

According to my research on information technology and linux based systems, I can say that based on the information provided within the question the name for this disk in linux is called an HDB. This refers to Hard Disk B, this is the case since it is a secondary master drive. While primary master drive would be called HDA or hard drive A.

I hope this answered your question. If you have any more questions feel free to ask away at Brainly.

8 0
3 years ago
Write a function solution that, given an integer N, returns the maximum possible
Elina [12.6K]

You did not specified the language, so I did my program in python.

Hope it helps!!!

3 0
3 years ago
when doing a complex presentation which of the fallowing will be the best tool to begin designing your presentation
qaws [65]

but where are the option bro

7 0
2 years ago
Read 2 more answers
Solid state storage stores data in erasable, rewritable circuitry, rather than on spinning disks, tape, or optical media.
Gwar [14]
It’s true because it’s also called “flash memory”
7 0
4 years ago
Other questions:
  • The difference between an AutoCorrect entry and a building block is that the building block feature makes corrections automatica
    6·1 answer
  • You can add envelopes to existing documents. <br> a. True <br> b. False
    10·1 answer
  • T-shaped, square-bottomed, dovetailed, and V-shaped are all types of _______ in a machined part. A. gears B. bolts C. lines D. s
    8·2 answers
  • The final step of the DHCP Discovery process is known as...
    8·1 answer
  • An audit trail is a record of how a transaction was handled from input through processing and output
    10·1 answer
  • What does the opacity effect do
    8·2 answers
  • Mack has started with his first photographic assignment for a magazine. He has clicked around thirty images and uploaded them on
    10·1 answer
  • 16. Budget Analysis Write a program that asks the user to enter the amount that he or she has budgeted for a month. A loop shoul
    14·1 answer
  • Describe the following types of Cloud services:
    11·1 answer
  • Television, the internet, and smartphones are different communication _______blank hsn uses in its imc.
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!