3. Program to find the Sum of give series.
a. (1)+(1+2)+(1+2+3)+(1+2+3+4)+………………………………..
b. 1/1+1/9+1/25+1/49+……………...
No Answer is Posted For this Question
Be the First to Post Answer
Write a program that takes a 3 digit number n and finds out whether the number 2^n + 1 is prime, or if it is not prime find out its factors.
Display Pattern: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 …
write a function – oriented program that calculates the sum of the squares from 1 to n. thus, if the input is 3, the output is 14
Implement a command console for changing settings on a particular object. The command console should allow you to enter a string and will return the response (very similar to a terminal session). The commands are as follows: SET propertyname=newvalue will change the target object’s member named “propertyname” to have a value equal to “newvalue”. If the input value is incompatible (i.e. an int being set to a string), print out an appropriate error message. GET propertyname will print out the current value of the target object’s member named “propertyname”. GET * will print out a list of all target object members and their current values. The system should be extensible for future commands and should accept an arbitrary object, such that another developer could insert another object into the system and rely on the command console to get and set the properties correctly.
0 Answers ABC, Guidance Software,
output for printf("printf");
Write an algorithm that receives a string and reverses it.
Write a C/C++ program that connects to a MySQL server and displays the global TIMEZONE.
0 Answers Facebook, Webyog, Wipro,
write a proram using exceptional handling create a error & display the message "THERE IS AN ERROR?... PLEASE RECTIFY"?
Where now stands that small knot of villages known as the Endians, a mighty forest once stood. Indeed, legand has it that you could have stoodon the edge of the wood and seen it stretch out for miles, were it not for the trees getting in the way. In one section of the forest, the trees stood in a row and were of hight from 1 to n, each hight occurring once and once only. A tree was only visible if there were no higher trees before it in the row. For example, if the heights were 324165, the only visible trees would have been those of height 3,4 & 6. Write a Program that takes an array of integers representing the heights of the trees in the row as input and prints the list of the visible trees.
write a program that reverses the input number of n.Formulate an equation to come up with the answer.
What output does the following code generate? Why? What output does it generate if you make A::Foo() a pure virtual function? class A { A() { this->Foo(); } virtual void Foo() { cout << "A::Foo()" << endl; } }; class B : public A { B() { this->Foo(); } virtual void Foo() { cout << "A::Foo()" << endl; } }; int main(int, char**) { A objectA; B objectB; return 0; }
write a program that prompt the user to enter his height and weight,then calculate the body mass index and show the algorithm used
0 Answers Jomo Kenyatta University,