Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Search & Filtering

Define a class called Odometer that can be used to track fuel and traveling distance for a car. Include private member variables to track the distance driven (in kms) and the fuel efficiency of the car in kilometers per liter. The class should have a constructor that initializes these values to zero. Include  a default constructor to initialize both member variables to zero,  a member function to reset the odometer to zero kilometers,  a member function to set the fuel efficiency,  a member function that accepts kilometers driven for a trip and adds it to the odometer’s total,  a member function that returns the number of liters of fuel that the car used since the odometer was last reset (this can be calculated using the distance driven and the fuel efficiency), and  a destructor. Use your class with a test program that creates odometers for different cars with different fuel efficiencies. Let the cars do several trips. Reset the odometers at the start of your program.

2.Find the regular expression defining each of the following language over E=[a,b].

i. All strings that do not end in a double letters.

ii. all strings in which letter never triples

iii. All strings in which 'a' is triple or 'b' is triple.


what will be the output of the variable L after the following code is executed?



Define a class Pairs with 2 integer data members, f & s, where f represents 

the 1st value in the ordered pair and s represents the 2nd value. Objects of type Pairs can be used wherever ordered pairs are 

needed.

The class must have a default constructor that initializes data members to 

0, & 2overloaded constructors, 1 with one int parameter and the other with 

2 int parameters. The 1-parameter constructor should initialise the 1st 

member of the pair; the 2nd member of the pair must be 0. The 2-parameter 

constructor must initialise both members of the ordered pair.

The class must have a destructor that outputs 'Bye'

Add accessor functions that return the values stored in each of the member

variables of an object of class Pairs & mutator functions to update each of the member variables of an object of class Pairs

respectively. The class must contain a void member 

function reset() that resets the member variables of a Pairs to values 

specified by parameters.


Write a program having following classes

Player (Base Class)

Members:

  • Show_Stats()
  • Other class variables and functions

Cricket player (Derived Class)


Members:

  • Show_Stats
  • Other class variables and functions

Hockey player (Derived Class)

Members:

  • Show_Stats
  • Other class variables and functions

Football player (Derived Class)

Members:

  • Show_Stats
  • Other class variables and functions


  • In the main function, make objects of each derived class and use their functions to show players statistics (e.g. for cricket player: Runs scored, Wicket taken etc. Similarly for Football, Goals scored etc)
  • Common variables/functions should be part of base class and additional members of each derived class will be part of them




Write a basic while loop with a function code in the program that sums a stream of integers (input from the keyboard) and continues to do so while the integer entered is not -999. Ask the user to enter values in the range of 1 to 10000 or -999 to quit.


For the given specification, construct a network design and assign the appropriate IP addresses for each interface in all the devices. Label all the devices with appropriate names given below with appropriate IP Addresses for each network and all the hosts connected in the each network. Suggested to use any Class C IP addresses for all the LAN and Class A address for the serial interface connecting between the two routers. Number of routers: Router A, Router B Number of switches: S1, S2, S3, S4 and S5 Number of LAN’s : 5 (Lab A, Lab B, Lab C, Lab D, and Lab E) Number of hosts connected in each lab are as follows: S0 in Lab A needs 10 hosts, S2 in Lab B needs 25 hosts, S3 in Lab C needs 100 hosts and S4 in Lab D needs 55 hosts, S5 in Lab E needs 5 hosts respectively


For the given IP address with subnet, identify the number of subnet, the valid host IP addresses for the given problem. Network address : 200.10.10.0 Number of needed usable hosts : 20 Address Class : ---------------- Number of host bits borrowed : ------------------------------ Default Subnet mask : ----------- Custom subnet mask : ----------- Total number of subnets : ------------------------------- Total number of host addresses : ------------------------------- Number of usable address : ------------------------------- i. What is the 7 th subnet range? ii. What is the subnet number for the 5 th subnet? iii. What is the broadcast address of the 4 th subnet? iv. What are the assignable addresses for the 6 th subnet?


For the given IP address with subnet, identify the number of subnet, the valid host IP addresses for the given problem. Network address : 195.223.50.0 Number of usable hosts needed : 45 Address Class : ---------------- Number of host bits borrowed : ------------------------------ Default Subnet mask : ------------------------------- Custom subnet mask : ------------------------------- Total number of subnets : ------------------------------- Total number of host addresses : ------------------------------- Number of usable address : ------------------------------- i. What is the 2 nd subnet range? ii. What is the subnet number for the 2nd subnet? iii. What is the broadcast address of the 4 th subnet? iv. What are the assignable addresses for the 3rd subnet?


Printers, Inc. is redesigning the network that connects its three locations. The administrator gave the networking team 192.168.11.0 to use for addressing the entire network. After subnetting the address, the team is ready to assign the addresses. The administrator plans to configure IP subnet-zero. As a member of the networking team, you must address the network and at the same time conserve unused address for future growth. With those goals in mind, choose the host addresses on the left to the correct router interface. All the routers interfaces are given below and one of the routers is partially configured. Not all of the host address on the left are necessary.As a computer user, how would you strengthen user authentication? The router interfaces are: Inkjet Fa 0/0 IP : Laser Fa 0/0 IP: Spooler Fa 0/0 IP: Inkjet S0/0 IP: 


LATEST TUTORIALS
APPROVED BY CLIENTS