हिंदी
तमिलनाडु बोर्ड ऑफ सेकेंडरी एज्युकेशनएचएससी विज्ञान कक्षा ११

What is an invariant? - Computer Science

Advertisements
Advertisements

प्रश्न

What is an invariant?

एक पंक्ति में उत्तर

उत्तर

An expression involving variables, which remains unchanged by an assignment to one of these variables is called an invariant of the assignment.

shaalaa.com
Invariants
  क्या इस प्रश्न या उत्तर में कोई त्रुटि है?
अध्याय 8: Iteration and recursion - Evaluation - Section - B [पृष्ठ ११३]

APPEARS IN

सामाचीर कलवी Computer Science [English] Class 11 TN Board
अध्याय 8 Iteration and recursion
Evaluation - Section - B | Q 1. | पृष्ठ ११३

संबंधित प्रश्न

We wish to cover a chessboard with dominoes, `square``square` the number of black squares, and the number of white squares covered by dominoes, respectively, placing a domino can be modeled by ______


If m x a + n x b is an invariant for the assignment a, b : = a + 8, b + 7, the values of m and n are ______


Which of the following is not an invariant of the assignment?

m, n := m + 2, n + 3


There are 7 tumblers on a table, all standing upside down. You are allowed to turn any 2 tumblers simultaneously in one move. Is it possible to reach a situation when all the tumblers are right-side-up?


A knockout tournament is a series of games. Two players compete in each game; the loser is knocked out (i.e. does not play anymore), the winner carries on. The winner of the tournament is the player that is left after all other players have been knocked out. Suppose there are 1234 players in a tournament. How many games are played before the tournament winner is decided?


King Vikramaditya has two magic swords. With one, he can cut off 19 heads of a dragon, but after that, the dragon grows 13 heads. With the other sword, he can cut off 7 heads, but 22 new heads grow. If all heads are cut off, the dragon dies. If the dragon has originally 1000 heads, can it ever die?


Assume an 8 × 8 chessboard with the usual coloring. "Recoloring" operation changes the color of all squares of a row or a column. You can recolor repeatedly. The goal is to attain just one black square. Show that you cannot achieve the goal.


Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×