write the code to reverse a string without using Strrev
built in function.

Answers were Sorted based on User's Feedback



write the code to reverse a string without using Strrev built in function...

Answer / fatekiller

code to reverse a string

first i wrote a function and then called that function to
reverse a string.


mystr=inputbox("enter the string")
ms=revstr(mystr)
print(ms)


Function revstr(mystr)
L=len(mystr)
revstrr=""
For i=0 to L-1
c=mid(mystr,L-i,1)
revstrr=revstrr&c

Next
revstr=revstrr
End Function

This program is written using the concept of MID function.

Is This Answer Correct ?    4 Yes 5 No

write the code to reverse a string without using Strrev built in function...

Answer / m.bindu kumar

'Code to reverse a string without using strrev using
functions

Function stringreverse(a)
strlen=len(a)
For i = strlen to 1 step -1
strrev=mid(a,i,1)
stn=stn+strrev
Next
msgbox stn
End function

Dim strrev,strlen, strname,stn
a=inputbox ("enter the string to reverse")
stringreverse(a)

Is This Answer Correct ?    3 Yes 6 No

write the code to reverse a string without using Strrev built in function...

Answer / ram

x="abcdefg"
v= len(x)
For i=1 to len(x)

newstr=mid(x, v,1)

a=a&newstr

v=v-1
Next


msgbox a

Is This Answer Correct ?    2 Yes 5 No

write the code to reverse a string without using Strrev built in function...

Answer / guest

strrev("star")

Is This Answer Correct ?    3 Yes 37 No

Post New Answer

More QTP Interview Questions

Shall we add Local Repository to shared object repository,if yes,how we add

4 Answers  


How to build scripts that access data from external sources?

0 Answers  


What is the use of "Step Generator" in QTP??for what purpose we are using??explain with an example

2 Answers  


I want to do QTP Certification what is the pattern of Question paper.

0 Answers  


How to test a web application using QTP?there is no any .exe file in web app,then how we can take the application for testing

2 Answers  


How do I lauch my test website using code from qtp in different environmet, uat and PPTE?

0 Answers  


I'm having a problem to get the status(pass or fail) during runtime for every iteration ran, and must get the results stored to an excel sheet if possible.

1 Answers   FAI,


What's Checkpoints for QTP?

1 Answers  


hi everyone today is the first time i saw this website,and hi iam siraj,iam very impressed by seeing evryones response towards questions,iam a newcomer and i have got tryining in testing can anyone please send me some projects relaited to testing.i know it is very confidential but still if u send it will a great help. my mail id venku_krs@yahoo.co.in

1 Answers  


Tell me Three major differences between QTP & Winrunner?

2 Answers  


Whenever we r keeping mouse pointer under the image we r getting image name. In qtp how can we do this thing.weather that name is coming or not?

5 Answers  


Hi Friends, Can anyone help me out in this one? In QTP, I am using Data Driver and want to parameterise multiple values (say 3 values ) for a field. How can I do it using Data Driver wizard? Plz mention it step-by-step. In the end after doing the needful, on opening the Data Driver window, how can I get number (i.e. 3) in the Parameterised column for that particualr value? Thanks a lot in advance.

0 Answers  


Categories