Interviewer And Interviewee Guide

SilkTest Interview Question:

How to retrieve the decimal part of value stored in float variable. Also how to retrieve the Integer part? Is there a function?

Submitted by: Administrator
the snippet code for the prob.
[ ] real rVal1=89.822 // Assume your real number is rVal1
[ ] integer iValue = [int]rVal1
[ ] real rVal2= rVal1-iValue
[ ] print(iValue) // Integer part of u r number
[ ] print(rVal2) // Decimal part of u r number
Submitted by: Administrator

Read Online SilkTest Job Interview Questions And Answers
Copyright 2007-2024 by Interview Questions Answers .ORG All Rights Reserved.
https://InterviewQuestionsAnswers.ORG.