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
Lena [83]
3 years ago
13

A class defined by a user (i.e., you, the programmer programmer) ... Group of answer choices might contain no data members -- on

ly methods. might contain no user-defined methods -- only data members. will result in compiler errors if no user-defined methods -- only data -- are in the class. will result in compiler errors if no data-- only user-defined methods -- are in the class. will always have both data members and methods.
Computers and Technology
1 answer:
Y_Kistochka [10]3 years ago
4 0

Answer:

might contain no user-defined methods -- only data attributes (members).

might contain no data attributes (members) -- only methods.

You might be interested in
Identify the type of error.<br> print "hello"<br><br> num = 5 / 0
horrorfan [7]

Answer:

Syntax error

Explanation:

This is a type of error that occurs when there is a problem with the code that makes it unable to compile and execute.

For example, making a conditional statement without using the correct parameters will result in a syntax error.

4 0
3 years ago
Read 2 more answers
Lottery Number Generator Design a program that generates a 7-digit lottery number. The program should have an Integer array with
Nikolay [14]

Answer:

/******************************************************************************

                             Online C++ Compiler.

              Code, Compile, Run and Debug C++ program online.

Write your code in this editor and press "Run" button to compile and execute it.

*******************************************************************************/

#include <iostream>

#include <string>

#include <sstream>

using namespace std;

bool equal(int sys[],int user[])

{

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

{

 if(sys[i]!=user[i]){

     return false;

 }

}

return true;

}

int main()

{

int sys[7];

int user[7];

int min=0

;int max=9;

string userinput;

while(0==0){

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

{

    sys[i]=rand() % (max - min + 1) + min;

}

cout <<endl;

   cout<<"enter numbers"<<endl;

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

{

 getline (cin,userinput);

    if(userinput=="x"){

        return 0;

    }

    else{

 stringstream(userinput) >> user[i];

   

    }

}

     cout<<"User number"<<endl;

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

{

    cout << user[i];

}

    cout<<"system number"<<endl;

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

{

    cout << sys[i];

}

if(equal(sys,user))

{

   cout<<"You won !"<<endl;

}else {

       cout<<"Try again :("<<endl;

}

}

   return 0;

}

Explanation:

Using c++ rand function generate a random number between 0-9.

Formula for random number is rand (max-min +1)+min.

Run this in a loop for 7 time and store each number to an array index in sys array which is for system generated number.

now using string take input from user and check if input is x close program else use stringstream to parse input string to int and store it in user array. Stringstream is a cpp header file used for parsing and handling of strin g inputs. Run this program in loop for 7 times.

Now create a function of type boolean denoted by "bool". This will take both arr as parameter and check if both are equal or not. It compares eac index of user array against each index of sys array and if both values are not equal returns false.

5 0
3 years ago
ASAP
grin007 [14]
I would recommend A. Quickly on the left and move ahead of it because you should always pass on the left and seeing as it is a large truck, you would want to get ahead of it ASAP.
4 0
3 years ago
Read 2 more answers
Anyone know how to fix this
gizmo_the_mogwai [7]

Put the mouse at the top of the black part and click and hold down, and then drag it down to the bottom. And don't feel embarrassed to ask somebody lol

3 0
3 years ago
Select the correct answer from the drop-down menu.
Eva8 [605]

Answer:

1. diagraph

2.analog

maybe

3 0
2 years ago
Other questions:
  • Oliver is creating an image of a fruit basket. From the basket, he wants the red apples to stand out among the rest so they will
    9·1 answer
  • What would happen if a pc that contains a power supply that does not automatically adjust for input voltage is set to 230 volts
    13·1 answer
  • How do you double space on microsoft word?
    5·1 answer
  • What best describes deflation?
    9·2 answers
  • Joe, a user, has purchased a new mobile device that uses a different OS than his previous one. Joe wants to copy his contacts an
    10·1 answer
  • Let X and Y be two decision problems. Suppose we know that X reduces to Yin polynomial time. Which of the following statements a
    14·1 answer
  • How are online sources used? Check all that apply.
    8·2 answers
  • Write a qbasic program to design any simple software with output ​
    5·1 answer
  • Draw a flowchart diagram for a program that displays numbers 1 to 20
    12·1 answer
  • How did the ENIAC change computing?<br> how did the eniac change computing
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!