Chef always likes to play with arrays. He came up with a new term"magical subarray". A subarray is called magical if its starting index is 1 (1-based indexing). Now, Chef has an array of N elements and 2 types of queries: type 1: Given two numbers i and x, the value at index ...
Chef always likes to play with arrays. He came up with a new term"magical subarray". A subarray is called magical if its starting index is 1 (1-based indexing). Now, Chef has an array of N elements and 2 types of queries: type 1: Given two numbers i and x, the value at index ...