M3 Part 8 1 / 50 Python में module का documentation देखने के लिए कौन सा function use होता है? help(module) module.doc() help(module) None 2 / 50 Python में package का main purpose क्या है? Module को hide करना Modules का organized collection Functions delete करना None 3 / 50 Python में global variable को nested function में modify करना possible है या नहीं? Only read possible None Yes, using global keyword No 4 / 50 Python में variable का lifetime किस scope पर depend करता है? Scope में Memory size None File 5 / 50 Python में module search order कौन सा है? Current directory → PYTHONPATH → Standard library → Installed packages Always standard library first Current directory → PYTHONPATH → Standard library → Installed packages Installed packages → Current directory → Standard library 6 / 50 Python में LEGB rule के अंतर्गत सबसे last scope कौन सा है? Local Enclosing Global Built-in 7 / 50 Python में nested function के variable को modify करने के लिए कौन सा keyword जरूरी है? static nonlocal global local 8 / 50 Python में module import करते समय alias देना optional है या mandatory? Optional Always required Depends on function Mandatory 9 / 50 Python में module को reload करने का function कौन सा है? importlib.reload() sys.reload() reload() os.reload() 10 / 50 Python में variable scope check करने के लिए क्या किया जा सकता है? locals() और globals() locals() और globals() functions print() None 11 / 50 Python में built-in functions के examples क्या हैं? sum(), len() max(), min() abs(), pow() All of these 12 / 50 Python में किसी module को uninstall करने के लिए क्या करना होगा? pip uninstall module_name remove module del module None 13 / 50 Python में module import करने पर क्या होता है? Error File copy होती है Memory में module load होता है Code available हो जाता है 14 / 50 Python में global और local variable का नाम same हो तो function में कौन सा use होगा? Both Global Local None 15 / 50 Python में package folder में किस file का होना जरूरी है? setup.py init.py None main.py 16 / 50 Python में module create करने के लिए file का extension क्या होना चाहिए? .exe .txt .py .mod 17 / 50 Local variable function के बाहर accessible होगा या नहीं? नहीं कभी-कभी None हमेशा 18 / 50 Python में scope को समझाने वाला mnemonic कौन सा है? GLOB LEGB (Local, Enclosing, Global, Built-in) None LEGB 19 / 50 Built-in function कौन सा है? All of these len() print() open() 20 / 50 Python में from module import func as f का मतलब क्या है? None Function delete करना func को f नाम से call करना Function rename करना 21 / 50 Module import करने के बाद उसके functions को call करने का सही तरीका कौन सा है? module.function_name() function_name() module_name.function_name() None 22 / 50 Python में standard library modules कहाँ stored होते हैं? Python installation folder Desktop Temp folder User directory 23 / 50 किसी module का alias use करने का फायदा क्या है? Shorter नाम से module call करना Memory save करना None Function delete करना 24 / 50 Python में nonlocal keyword का use कब होता है? Nested function के enclosing variable को modify करने के लिए None Local variable delete करने के लिए Global variable modify करने के लिए 25 / 50 Python में किसी global variable को function के अंदर modify करने के लिए क्या करना जरूरी है? global keyword use करना Assign directly nonlocal keyword use करना कुछ नहीं 26 / 50 अगर किसी module का नाम और user variable का नाम same हो तो क्या होगा? Variable module को overwrite कर देगा Error Module variable को overwrite Error 27 / 50 Python module को reload करने के लिए कौन सा function use होता है? sys.reload() importlib.reload() os.reload() reloadmodule() 28 / 50 Python में किसी module का memory location जानने के लिए कौन सा attribute use होता है? module.location module.file module.memory None 29 / 50 Python में package क्या है? Data type Modules का collection (folder with init.py file) Function Only a file 30 / 50 Current working directory पता करने के लिए os module का कौन सा function use होता है? os.path() os.folder() os.getcwd() os.dir() 31 / 50 Command line arguments handle करने के लिए कौन सा module use होता है? random string sys os 32 / 50 Operating system से related functions (जैसे file, directory handling) किस module में होते हैं? math os random sys 33 / 50 Random numbers generate करने के लिए कौन सा built-in module use होता है? sys random math os 34 / 50 Built-in modules कहाँ से आते हैं? Third party software से None Python Standard Library से User से 35 / 50 अगर हम from math import * लिखते हैं, तो क्या होगा? Error math module के सारे functions import होंगे कुछ भी import नहीं होगा केवल एक function import होगा 36 / 50 किसी module से केवल specific function import करने के लिए कौन सा syntax सही है? from module_name import function_name None import module_name : function_name include function from module 37 / 50 किसी module को alias (short name) से use करने के लिए syntax क्या है? import module_name as short_name include module alias module import alias import module as alias 38 / 50 Python में किसी module को import करने के लिए कौन सा keyword use होता है? include import require use 39 / 50 Module क्या है? Only a package Python file (.py) जिसमें variables, functions, classes defined हों None Only a file 40 / 50 अगर function में local और global दोनों variables same name के हों तो कौन सा execute होगा? Local Error Global दोनों 41 / 50 Built-in scope में कौन से variable आते हैं? Python के default functions और exceptions (जैसे len(), print(), etc.) None File variables User defined variables 42 / 50 Python में किसी variable को enclosing scope से access करने के लिए कौन सा keyword use होता है? nonlocal local global static 43 / 50 Nested function के variable किस scope में आते हैं? Local Built-in Enclosing Global 44 / 50 Python में किसी variable को explicitly global declare करने के लिए कौन सा keyword use होता है? global static extern public 45 / 50 अगर function के अंदर variable define किया गया है, तो वह default किस scope में होगा? Local Built-in Enclosing Global 46 / 50 Global scope का मतलब क्या है? पूरे program में accessible variable केवल module तक केवल loop तक केवल एक function तक limited 47 / 50 Local scope कहाँ applicable होता है? Built-in function में Function के अंदर define variable के लिए Module में पूरे program में 48 / 50 LEGB rule का मतलब क्या है? None Local, External, Global, Base Loop, Execution, Global, Built-in Local, Enclosing, Global, Built-in 49 / 50 Python में कितने प्रकार के Scope होते हैं? 2 5 3 4 (Local, Enclosed, Global, Built-in) 50 / 50 Python में scope का मतलब क्या है? Function name Variable की visibility और accessibility area File size Memory size Your score isThe average score is 72% 0% Restart quiz