Answer Posted / prk
void main()
{
int i,n,k;
cout<<"Enter the number:";
cin>>n;
k=n%2;
if(k==0)
n=n-1;
for(i=n;i<=n;i=1-2)
cout<<1;
}
Is This Answer Correct ? | 9 Yes | 15 No |
Post New Answer View All Answers
Why should you learn c++?
what is data encapsulation in C++?
What are single and multiple inheritances in c++?
What is runtime polymorphism in c++?
Which is not an ANSII C++ function a) sin() b) tmpnam() c) kbhit()
How do I write a c++ program?
How will you call C functions from C ++ and vice-versa?
When is the copy constructor called?
What are special characters c++?
What is encapsulation in c++?
What is a tree in c++?
Explain the volatile and mutable keywords.
What is the purpose of the "delete" operator?
Write a program to encrypt the data in a way that inputs a four digit number and replace each digit by (the sum of that digit plus 7) modulus 10. Then sweep the first digit with the third, second digit with the fourth and print the encrypted number.
What are put and get pointers?