@@ -77,10 +77,10 @@ def get_ans(self, questions_list):
7777 This function prints the answer to the queries
7878 (question and tags) provided by the user. It does so
7979 in the following manner :
80- 1) Gets the details of all the relavant question and stores their title, link and id in "question_data" list.
80+ 1) Gets the details of all the relevant question and stores their title, link and id in "question_data" list.
8181 2) I have introduced the concept of active question, i.e. , the question whose answer is currently being displayed.
8282 3) The index of the active question in "question_data" array is stored in "question_posx"
83- 2) By Default, shows the answer to the first question. Creates an breakable infinite loop asking the user asnwer to which question he wants to see.
83+ 2) By Default, shows the answer to the first question. Creates an breakable infinite loop asking the user answer to which question he wants to see.
8484 4) The value of "question_posx" changes according to user input, displaying answer to different questions in "questions_data" list.
8585 3) The answers to the questions requested by the user are stored in cache for faster access time during subsequent calls.
8686 """
@@ -145,7 +145,7 @@ def get_ans(self, questions_list):
145145
146146 console .print (output_text )
147147 # If the cache has no entry for the said question id, then downloads the answer
148- # and makes an entry for it in the said format and restarts the loop.
148+ # and makes an for it entry in the cache array in the said format and restarts the loop.
149149 else :
150150 try :
151151 resp = requests .get (
@@ -162,7 +162,7 @@ def get_ans(self, questions_list):
162162 continue
163163
164164 console .rule ("[bold blue]" , style = "bold red" , align = "right" )
165- # Asks the user for next question number. Makes it the active question and loop restarts
165+ # Asks the user for next question number. Makes it the active question and the loop restarts
166166 while True :
167167 posx = int (input ("Enter the question number you want to view (Press 0 to quit): " )) - 1
168168 if (posx == - 1 ):
0 commit comments