[gtranslate]

two-array-members-are-equal-or-not

Checking Two Array Members Are Equal Or Not | C++

Source Code #include<iostream> using namespace std; int main() {       int array1[5], array2[5];             int members1, members2;        cout << “Enter numbers in first Array” << endl;        for(members1 = 0; members1 < 5; members1 ++)        {               cin >> array1[members1];        }        cout << “Enter numbers in second Array” << endl;        for(int […]

finding-index-of-element-in-array

Using Array Finding Element in Index of Array | [*Solved*] | C++

Source code #include<iostream> using namespace std; int main() {        int enter;        int find[6];        cout << “Enter Numbers to save in array” << endl;        for(int i = 0; i < 6; i ++)        {               cin >> find[i];        }        cout <<“Enter a Number you want to see the address […]

prog

Input Numbers Until -ive # Entered & Count| if Condition | C++

Write a program that inputs numbers from the user till the user inputs a negative number. The program should then print the total number of times the number 1 was Coding #include<iostream> using namespace std; int main() {       int i = 1;       int j=0;      cout<<“Please enter a number, and When finished, […]

counter-class-oop

Print “I am object number –” | [Solved] | Classes | OOP | C++

Create a class that includes a data member that holds a “serial number” for each object created from the class. That is, the first object created will be numbered 1, the second 2, and so on. To do this, you’ll need another data member that records a count of how many objects have been created […]

tollbooth-class

Imagine a tollbooth at a bridge | [Solved] | Classes | OOP | C++

Imagine a tollbooth at a bridge. Cars passing by the booth are expected to pay a 50-cent toll. Mostly they do, but sometimes a car goes by without paying. The tollbooth keeps track of the number of cars that have gone by, and of the total amount of money collected. Model this tollbooth with a […]