how to swap two strings without using any third variable ?
Answer Posted / kollu.praveen
var1="String1"
var2="String2"
var1=var1+var2
var2=mid(var1,1,Len(var1)-Len(var2))
print var2
var1=mid(var1,(Len(var1)-Len(var2)+1),(Len(var2)+1))
print var1
| Is This Answer Correct ? | 0 Yes | 2 No |
Post New Answer View All Answers
How long does it take to get good at leetcode?
What are libraries in c++?
What are c++ stream classes?
What ANSI C++ function clears the screen a) clrscr() b) clear() c) Its not defined by the ANSI C++ standard
Describe linked list using C++ with an example.
Is c++ faster than c?
Explain how would you handle a situation where you cannot call the destructor of a local explicitly?
write a program that withdrawals,deposits,balance check,shows mini statement. (using functions,pointers and arrays)
What are pointers used for c++?
Can you help me with this one? Make a program that when a user inputed a Product Name, it will display its price, and when the user inputed the quantity of the inputed product, it will show its total price. The output must be like this: Product Name: Price: Quantity: Total Price: ..this is the list of products to be inputed: Cellphone - 1500 Washing Machine - 5200 Television - 6000 Refrigirator - 8000 Oven - 2000 Computer - 11000 thanks..:D
Is c++ a pure oop language?
Explain selection sorting. Also write an example.
Differentiate between C and C++.
Why we use #include iostream in c++?
What does obj stand for?