Question
Easy
Solution to recurrence relation $T(n)=T(n-1)+2$ is given by, where $n>=0$ and $T(0)=5$
1
$T(n)=2n-5$
2
$T(n)=n-5$
3
$T(n)=2n+5$
4
$T(n)=n-3$
Question Details
Time to Solve: 12
Exam: HTET
Level/Paper: Level 3
Chapter: Software Engineering & Problem Solving
Topic: Programming Concepts
Correct Answer
Option C
Explanation
The correct option is (3): The recurrence relation $T(n)=T(n-1)+2$ is a simple first-order linear recurrence relation that represents an arithmetic progression, where the term for $n$ is always 2 greater than the term for $n-1$. To solve this and find a closed-form expression, we use the method of iteration (or unrolling). Starting with $T(n)$, we substitute the relation repeatedly: $T(n) = T(n-1) + 2 = (T(n-2) + 2) + 2…Read More
Similar Questions from HTET Exam - Level 3 - Year 2019
Question 1
Easy
Source :
HTET 2019
SQL command used to modify attribute values of one or more selected tuples is :
Chapter :
Database Management System (DBMS) & SQL
Topic :
SQL
Question 2
Easy
Source :
HTET 2019
Which of the following feature is not supported in C++?
Chapter :
Computer System & Hardware Fundamentals
Topic :
Computer System
Question 3
Easy
Source :
HTET 2019
_______ is used to declare and initialize an object from another object of same class in C++.
Chapter :
Object-Oriented Programming (C++)
Topic :
Advanced Class Concepts
Question 4
Easy
Source :
HTET 2019
There are several common terminologies used for signal rate in the literature of computer networks. Which of the following is not a common terminology for…
Chapter :
Computer Networks & Internet
Topic :
Computer Network