1,521 Answered Questions for the topic computer science

Computer Science Computer Programming

03/02/20

Write a class with constructors and destructors functions.

A point in a two-dimensional plane having coordinate as (x,y), can be represented by a class whose private data members are x and y. Write the constructor and destructor functions of the class. The... more

03/02/20

Constructors and destructors

Write a program to show that, the constructor and destructor functions of a globally declared object are the first and last functions, respectively to be called in a program.

03/02/20

Constructors with overloading and with default parameters

Write a program to show that constructors follow the property of function overloading as well as default parameter. Also, show that in case of constructor also, default parameter may create problem... more

03/01/20

Write a class in c++

Write a class definition for an order class for a nightclub that contains a table number, a servers name, and the number of patrons at the table. Include a private static data member for the table... more
Computer Science Computer Programming

03/01/20

Create a class in c++

Define a class named Movie. Include private fields for the title, year, and name of the director. Include three public functions with the prototypes void Movie::setTitle(string); , void... more
Computer Science Computer Engineering

03/01/20

Write a function

Write a function that accepts two arguments: a string name of a movie and an integer running time in minutes. Provide a default value for the minutes so that if you call the function without an... more
Computer Science Math

02/25/20

Determine the value for the following recursive method when x = 20.

Question options: 1) 9 2)  4 3)  -5 4)  -4 5)  2
Computer Science Math

02/25/20

Determine the value for the following recursive method when x = 25.

Question options: 1) 7 2)  -5 3)  -2 4)  -3 5)  2

02/25/20

Write a C++ program

Suppose you have to develop small software to assist the primary students. Write a program that will help an elementary school student learn multiplication. Use the rand function to produce two... more
Computer Science Computer Programming

02/22/20

How do I write this program into a text file

#include <iostream>#include <fstream>#include <string>#include <cstring>#include <cstdlib>#include <iomanip>using namespace std;// global declarations for... more
Computer Science

02/21/20

creating frames

Using Classes/ObjectsPart-1 Create 3 frames Place 2 frames side-by-side on top of the screen Place the 3rd frame below the top 2 frames, spanning two columns Display a picture in one of the top 2... more
Computer Science

02/20/20

how to make a list for students

Using Classes/ObjectsPart-1 Create 3 frame/label objects Place 2 objects side-by-side on top of the screen Place the 3rd object below the top 2, spanning two columns Display a picture in one of the... more
Computer Science

02/20/20

Binary Math computer science

Complete Twos Compliment 8-bit Binary Math on the following expression: 25-68
Computer Science Computer Programming

02/19/20

Which of the following functions are in cstdlib.h? Check all that apply

a) ispunct b) strlen c) toupper d) strcmp e) atol f) atof
Computer Science Computer Programming

02/19/20

Which of the following file access flags will create a file when an attempt is made to open a file that doesn't exist?

a) ios::trunc b) ios::out c) ios::in d) ios::app e) ios::ate f) ios::binary
Computer Science Computer Programming

02/19/20

Which of the following character functions will return a non-zero integer when a space is passed into the function? Check all that apply.

a) ischar b) isvalid c) isspace d) ispunct e) isprint f) isalnum
Computer Science Computer Programming

02/19/20

Which of the following C code segments is syntactically correct?

a) puts("How many red mana do you want to tap?"); scanf("%d", &rmana); b) printf("How many green mana do you want to tap?"); scanf("%i", gmana); c) scanf("How many blue mana do you... more
Computer Science Computer Programming

02/19/20

Which is true of both recursion and iteration? Check all that apply

a) both have a termination test b) both have high overhead costs c) both based on a control structure d) both could happen infinitely in theory e) both use repetition
Computer Science Computer Programming

02/19/20

Which error bits can be reset to zero by using the clear() function? Check all that apply.

a) ios::failbit b) ios::clearbit c) ios::badbit d) ios::hardfail e) ios::goodbit f) ios::eofbit
Computer Science Computer Programming

02/19/20

What type of recursion is illustrated below?

void Player4() { //Player 4's turn //... Player1(); } void Player3() { //Player 3's turn //... Player4(); } void Player2() { //Player 2's turn //... Player3(); } void... more
Computer Science Computer Programming

02/19/20

What is the output of the code segment below? Assume all necessary libraries have been included.

fstream train; train.open("TTR_Rules.txt", ios::in|ios::out); char ch; train.seekp(10, ios::beg); train.seekg(-2, ios::cur); train.seekp(10 + train.tellg() - 3); train.get(ch); cout... more
Computer Science Computer Programming

02/19/20

Identify the errors (syntax or logical) in the following code segment. Select all that apply.

char game[10]; getline(game, 9); if (game == "Zombicide") cout << game; a) declaration of the variable game b) checking the value of game c) using getline to read data for game d)... more
Computer Science Math Science Computer Programming

02/12/20

Does an adjacency matrix need to have equal rows and columns?

If it needs to be the same number of rows and columns, then why? If not, then why not?
Computer Science Math Science Computer Programming

02/12/20

Does an adjacency matrix need to have equal rows and columns?

If it needs to the same number of rows and columns, then why? If not, then why not?
Computer Science

02/11/20

How do you write an appointment system in Python programming language ?

Appointment System – write a python program in which a professor can pre-populate available time slots for students to select to be advised. It can also send reminder emails to all students with... more

Still looking for help? Get the right answer, fast.

Ask a question for free

Get a free answer to a quick problem.
Most questions answered within 4 hours.

OR

Find an Online Tutor Now

Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.