Programming & Computer Science Answers

C++ 9913
Python 5288
Java | JSP | JSF 3611
C 1680
C# 1362
Computer Networks 989
Algorithms 652
Databases | SQL | Oracle | MS Access 641
HTML/JavaScript Web Application 588
Other 537
Visual Basic 358
Assembler 209
Software Engineering 202
AJAX | JavaScript | HTML | PHP 166
MatLAB 150
MatLAB | Mathematica | MathCAD | Maple 124
Action Script | Flash | Flex | ColdFusion 112
UNIX/Linux Programming 89
Web Development 73
Excel 36
ASP | ASP.NET 23
Delphi | Pascal 21
Perl 16
Prolog 9
Functional Programming 9
MathCAD 5
Wolfram Mathematica 4
WPF 4
Ruby | Ruby on Rails 3
NodeJS Web Application 2

Questions answered by Experts: 26 876

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

Given an array storing integers ordered by value, modify the binary search routine to return the position of the first integer with value K in the situation where K can appear multiple times in the array. Be sure that your algorithm is that is, do not resort to sequential search once an occurrence of K is found.


Write a program to take a String name as input then display the name's first and last words as it was and the middle will be only first letter using substring and indexOf.

Example:

Enter a String

Meser chen Rixou xang

Meser c.R. xang

Don't use array and split


Prof. Abhiram has taken an exam of his students. He has stored the marks of students in a dictionary where keys are the student’s name and values in the dictionary are student marks. Now he wants to know the name of students obtained minimum and maximum marks from this dictionary. You need to write a python function Find_Min_Max(A)  which takes a dictionary as input parameter and return the name of student pair having minimum and maximum marks in the class as shown in the example.


 

Example-1

Example-2

Input:

{'Theodore': 19, 'Roxanne': 22, 'Mathew': 21, 'Betty': 20}

 

Output:

('Theodore', 'Roxanne')

Input:

{'Roudy': 9, 'Alexa': 2, 'Prett': 18, 'Holmes': 22}

 

Output:

('Alexa', 'Holmes')



An academic department of Information School wants to generate students report for TEN final year students which will be graduated soon. A name list of TEN students and their FOUR scores are stored in arrays. Write a complete C++ program to do the following:

a. Create 5 parallel arrays to store the:

i. TEN students name called studentName

ii. TEN scores for subject CS402 called cs402

iii. TEN scores for subject CS315 called cs315

iv. TEN scores for subject CS607 called cs607

v. TEN scores for subject CS558 called cs558

b. Read input into the arrays and display them.

c. After processing all the information, the program should:

i. Calculate the average marks for each student

ii. Determine how many students are graduated with first class degree, with average score more than 80%.

iii. Display best student with highest score of each subject iv. Display best student with the highest average score to be awarded with chancellor award


create a C++ program using Microsoft Visual Studio to do the following tasks:



Prompt the user for the salary per year and calculate a Christmas bonus based on the number of years worked as follow. Between 1 to 5 years 1% of salary, and more than five years 2% of salary. Any other values should be considered as an error message.




Even Out

by CodeChum Admin

You know, I was lying when I said the last time that numbers associated with 3 are my favorite, because the one I actually like the most in the world are even numbers! But to make things harder for you, you have to pick the even numbers from a range of two given numbers. Ha!

Now, let's try this one more time! 


Instructions:

  1. Input two integers in one line, separated by a space. The first integer shall represent the starting point, and the other, the ending point.
  2. Print out all even numbers that are within the range of the starting and ending point (inclusive or including the ending point).

Input

A line containing two integers separated by a space.

5·10

Output

A line containing integers separated by a space.

6·8·10





3. Student Storage

by CodeChum Admin

Given the Student class that inherited from the Person class (the same ones from our lesson), construct another class called StudentAssistant. The class inherits from Student. What makes a StudentAssistant different from Student is that they have to render a fixed set number of hours. All student assistants are to render at least 40 hours of duty in a month. This maybe changed at any time by the Administrator.


More Info here, Important!

https://pastebin.com/PKEgsRSQ


2. Fraction/Mixed Fraction

by CodeChum Admin

 

Given the class Fraction in the code editor. Fill in the operations and display for the class Fraction. For plus and minus, think cross multiplication. times is straightforward, while divide has to do with reciprocals. toString should return the fraction in string format ("nume/deno" - as a String) but if denominator is 1, then the string should just contain the numerator.


More info here, Important!

https://pastebin.com/VRkEAe6g


2. Rectangle

by CodeChum Admin


A rectangle can be formed given two points, the top left point and the bottom right point. Assuming that the top left corner of the console is point (0,0), the bottom right corner of the console is point (MAX, MAX) and given two points (all "x" and "y" coordinates are positive), you should be able to draw the rectangle in the correct location, determine if it is a square or a rectangle, and compute for its area, perimeter and center point.


More details here, Important!

pastebin.com/8NDksx9M


1. Air Conditioning Unit

by CodeChum Admin

Construct a class to represent an air conditioning (AC) unit containing the following attributes:

  • brand - name of manufacturers like Samsung, LG, Carrier, etc.
  • type - whether it is an inverter type or not
  • power - represents the status of the AC unit whether it is turned on or not
  • thermostat - levels go from 1 to 10
  • temperature - levels go from 16 to 30 (in .5 intervals)
  • It should have two constructors - one default and another that is overloaded
  • default constructor
  • sets all the numerical values to the least value as described above
  • sets power to off, and type to inverter
  • sets brand to "AC Brand"
  • prints "Default Constructor"
  • overloaded constructor
  • accepts brand and type as arguments
  • everything else is set to the same values as in the default constructor
  • prints "Overloaded Constructor"


More details here, Important!

https://pastebin.com/yx0z0Tfr


LATEST TUTORIALS
APPROVED BY CLIENTS