hi all
i have a C++ assinment and i can't solve it can anyone help me to solve it is three questions:
Q1. Write a C++ program that sends a pointer of an array of characters to function with the function profile void Analyze ( char *abc) . Function Analyze will print number of characters , number of spaces , number of words, number of lower case and number of upper case characters in the array.
you have to use arrays and pointers only; it is not allowed to use any string nor string functions.
Hint: use ASCII table.
Sample output:
For the following string:
" I am a C++ programmer"
The number of characters is: 17.
The number of spaces is: 4.
The number of words is: 5.
The number of upper case characters is: 2.
The number of lower case characters is: 13.
----------------------------------------------------------------------------
Q2. Implement a class RectangularCuboid which has width, length and depth. The initial values of the data members should be 1 . (the data members cannot be set to 10)
your class should contain a function setDimensions that should take the depth, length and hieght from the caller , check if the calues are valid and store them . You should implement a function named calculate that should return the area , volume and circumference together ( use an appropriate method to return all of them in one call)
----------------------------------------------------------------------
Q3. Write a function that can solve two linear equations with two unknowns. The solution should be returned through pointers or reference parameter. The main program should read the six coefficients, call the function, and display the solution.
a . x + b . y = c
d . x + e . y = f
----------------------------------------------------------------------
these all the question hope that u will help me to solve them because i tried but am too weak in programming please help me ...