Could Anybody tell me the VBscript for
REVERSE an Integer int reverse(int num) Ex:246 to 642

Answers were Sorted based on User's Feedback



Could Anybody tell me the VBscript for REVERSE an Integer int reverse(int num) Ex:246 to 642..

Answer / naga siva sankar

val=246
valstr=cstr(val)
msgbox strReverse(valstr)

Is This Answer Correct ?    11 Yes 5 No

Could Anybody tell me the VBscript for REVERSE an Integer int reverse(int num) Ex:246 to 642..

Answer / anil

Dim x,y,n
x=246
n=len(x)
for i=1 to n
y=mid(x,i,1)+y
next
msgbox y

Is This Answer Correct ?    8 Yes 3 No

Could Anybody tell me the VBscript for REVERSE an Integer int reverse(int num) Ex:246 to 642..

Answer / arpita

n=123
Do While n>0
i=n mod 10
vstr=vstr&i
n=n\10

Loop
msgbox vstr

Is This Answer Correct ?    5 Yes 1 No

Could Anybody tell me the VBscript for REVERSE an Integer int reverse(int num) Ex:246 to 642..

Answer / pankaj jaju

Function IntReverse(varNum)
Dim varTemp

If IsNumeric(varNum) = True Then
varTemp=0
While (varNum/10) > 0
varTemp = (varTemp*10) + (varNum Mod 10)
varNum = Int(varNum/10)
Wend
IntReverse = varTemp
Else
IntReverse = False
End If
End Function

Is This Answer Correct ?    3 Yes 1 No

Could Anybody tell me the VBscript for REVERSE an Integer int reverse(int num) Ex:246 to 642..

Answer / kiran

dim number
number = inputbox("enter any number")
strlen = len(number)
for i = 1 to strlen
revnumber = mid(number,i,1) + revnumber
next
msgbox revnumber

Is This Answer Correct ?    3 Yes 1 No

Could Anybody tell me the VBscript for REVERSE an Integer int reverse(int num) Ex:246 to 642..

Answer / manish

a = inputbox("enter a string or no.")
b = len(a)
For i = 1 to b
c = mid(a,b,1)
d = d & "" & c
b = b -1
Next
msgbox d

Is This Answer Correct ?    1 Yes 0 No

Could Anybody tell me the VBscript for REVERSE an Integer int reverse(int num) Ex:246 to 642..

Answer / lak

n=Inputbox("Enter Number Series to reverse")

for i=1 to len(n)
x=n mod 10
temp=temp&x
n=n/10
n=fix(n)
next

msgbox temp

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More VB Script Interview Questions

How can you have different number of cells for each row of a table in HTML?

2 Answers  


What is loose binding? Why is it not a good practice to use it?

0 Answers  


Which keyword is used to declare a variable in the vbscript language?

0 Answers  


What is wrong with the following code: <%afname="header.asp"%><!?#include file ="<%=afname%>"?>

1 Answers  


How to scroll down a page while recording in qtp. suggest me any method apart from low level recording.

0 Answers  






How to check the particular window is exist or not with out using check points

2 Answers  


Can someone please tell me what poor design in a relational database (not the layout or style) is and how it can be avoided? PLEASE...im desperate.

0 Answers  


In html file what is an ideal position to include vbscript?

0 Answers  


What variable can you use to share info across the whole application for one user?

2 Answers  


How to make sure that items in a wintree are sorted al?

0 Answers   Ness Technologies,


Which operator is used to concatenate the 2 values in the vbscript language?

0 Answers  


write a program to display the system specifications of client system with the help of vb script.

1 Answers  


Categories