Answer:
#include <iostream>
#include <map>
using namespace std;
int main()
{
map<int, int> numbers;
cout << "Enter numbers, 0 to finish" << endl;
int number;
while (true) {
cin >> number;
if (number == 0) break;
numbers[number]++;
}
for (pair<int, int> element : numbers) {
std::cout << element.first << ": occurs " << element.second << " times" << std::endl;
}
}
Explanation:
One trick used here is not to keep track of the numbers themselves (since that is not a requirement), but start counting their occurrances right away. An STL map< > is a more suitable construct than a vector< >.
The Rearrangement of the words are:
- Ear map
- Rent cup
- METREON
- Sister or
- Sister Cane
<h3>What is arrangement of words?</h3>
A sorting method is known to be the orders of entries that are based on each word or phrase found in a heading, e.g. spaces, etc.
The Rearrangement of the words are:
- Ear map
- Rent cup
- METREON
- Sister or
- Sister Cane
Learn more about Arrangement from
brainly.com/question/984329
#SPJ1
Answer:
// here is code in C.
// headers
#include <stdio.h>
// main function
int main(void) {
// variable declaration
int favorite_number;
// ask user to enter favorite number
printf("enter your favorite number : ");
// read the number
scanf("%d",&favorite_number);
// print the message
printf("your favorite number is: %d",favorite_number);
return 0;
}
Explanation:
Declare a variable "favorite_number" of integer type.Ask user to enter favorite number and assign it to favorite_number.Then print the message which include the favorite number.
Output:
enter your favorite number : 77
your favorite number is: 77
In a category of games known as MMORPGs, millions of players connect to various servers to team up with other players in very large virtual worlds.
<h3>What do MMORPGs mean?</h3>
The term MMORPG connote massively multiplayer online role-playing games.
This is known to be a type of video game that tends to make use of different elements of role-playing games (RPGs) along with those of the gameplay of multiplayer online gaming worlds.
Therefore, In a category of games known as MMORPGs, millions of players connect to various servers to team up with other players in very large virtual worlds.
Learn more about virtual worlds from
brainly.com/question/13873769
#SPJ1