Question
Consider the following code: let data = [1, 2, 3]; function modifyArray(arr) { arr.push(4); arr = [5, 6]; // Reassigns local 'arr' return arr; } let result = modifyArray(data); console.log(data); console.log(result); What will be the output?
More IT Operating System Questions
- Which cloud deployment model is suitable for government organizations with strict regulations?
- In PAM technique which of the below attributes of the pulse is used to vary as the amplitude of message varies
- A processor uses a write-back cache policy rather than write-through. What is the primary trade-off this design choice introduces?
- Python's built-in dict (dictionary) data structure is typically implemented using a hash table. What is the average-case time complexity for get, set, and ...
- Given the string S = "aabaaab" for Z-Algorithm, what is the Z-array for this string? (Z is typically 0 or undefined).
- What is the recurrence relation for Merge Sort?
- Which type of operating system processes a group of jobs together without user interaction during their execution?
- A page has 2^12-byte size and a logical address is 32 bits. How many bits identify the page number?
- Does Dijkstra's algorithm work for graphs with both negative and positive edge weights?
- Which of these is a distributional representation for words?
Hey! Ask a query
Please enter email id
The email must be a valid email address.
Please enter Mobile Number
Please enter valid Mobile Number
Please enter your Doubt
Think You're Ready for RBI Grade B?
RBI Grade B 2026 Phase 1 Memory Based Paper
- 200 Questions with Detailed Solutions
- Section-wise Coverage (GA, English, Quant & Reasoning)