Write a program that would find the nth term of a geometric
progression, given the value of
first term and common ratio. Any inbuilt function that the
language provides for calculating
exponent should not be used.
Answer / Pankaj Kumar Verma
VB.NET Code: (This code doesn't use any built-in functions to calculate exponent.)
```vbnet
Public Function GetNthTerm(ByVal firstTerm As Decimal, ByVal commonRatio As Decimal, ByVal n As Integer) As Decimal
Dim term As Decimal = firstTerm
For i As Integer = 1 To n - 1
term *= commonRatio
Next
Return term
End Function
| Is This Answer Correct ? | 0 Yes | 0 No |
How many ways the function can return values?
Write program in VB.Net with SQL Server and Crystal Reports to develop a small windows application to add,edit,save, search and print Employee Information and send sourcecode as zip file. empcode : .............. empname : .............. dateofjoin : dd/mm/yyyy dateofbirth : dd/mm/yyyy TableName: EmpMaster EmpCode EmpName DOB DOJ TableName: EmpDocs EmpCode DocNo DocName ExpDate
What is the difference between Dataset and Recordset?
Describe about visual basic.net?
what is the dif b/w panel and groupbox.
Name the class which allows an element to be accessed using unique key?
What is the main use of a namespace?
Is vb net a scripting language?
How do you script this scenario in QTP using VB? Verify XML attributes in XML message against XSD and data mapping of fields to Oracle tables? Verify data in XML to data in a defined table?
What is the difference between a "jagged array" and multidimensional array" ?can anyone show me it practically ?
What are the different types of applications supported in .net (or) .net framework?
What is the Advantage of vb.net over vb
Visual Basic (800)
C Sharp (3816)
ASP.NET (3180)
VB.NET (461)
COM+ (79)
ADO.NET (717)
IIS (369)
MTS (11)
Crystal Reports (81)
BizTalk (89)
Dot Net (2435)
Exchange Server (362)
SharePoint (720)
WCF (340)
MS Office Microsoft (6963)
LINQ Language-Integrated Query (317)
WPF (371)
TypeScript (144)
Microsoft Related AllOther (311)