Question
What is the outpur of the following part of python
program? s="india" 1=0 for x in s: if(X!="i"): 1=1+1 else: pass print(1)Solution
- String "india" → characters = i, n, d, i, a
- Condition if(x != "i") counts all characters except "i" .
- "n" , "d" , "a" satisfy condition → count = 3.
- Output = 3 .
- Why Others are Wrong:
- 1: Wrong, only counts one.
- 5: Would mean all counted.
- 6: Impossible (string length is 5).
When any person has reason to believe that he may be arrested on an accusation of having committed a non bailable offence he may apply for anticipatory...
The Central Vigilance Commission is classified as a:Â
Consider the following statements regarding adjudicating officers under the IT Act, 2000:
1. They are appointed by the Central Government.
The assessment of land revenue on any land shall be made with reference to the use of land.
When is a principal required to compensate their agent under the Special Contract Act?
Under the Occupational Safety, Health and Working Conditions Code, how many days in a week can a worker typically be allowed to work in an establishment?
Section 17(1) proviso of the Environment (Protection) Act, 1986 provides defense to Head if he proves offence committed:
When consent to an agreement is caused by coercion, fraud or misrepresentation, the agreement is a contract :Â
After retirement, a Judge of a High Court can undertake practice in-
Under Section 37(1) of the BNS, 2023, which of the following acts does NOT allow the exercise of the right of private defence?Â