Computer Science, asked by dinakarparul69, 1 month ago

Question 2
Zerofy the array
You are given an array A of N positive integers (including zero). You can do the following operation on each array element
Ai (1 Si< N) any number of times
1. Subtract 1
2. Subtract a prime number
Note
Array A follows one-based indexing.
Task
Your task is to determine the minimum total number of operations to change all the array elements into zero
Example
If an array element is 4, you can change it to o in the following two operations.
1. Subtract 3 (prime number) from 4 such that the element becomes 1.
2. Subtract 1 from 1 such that the element becomes 0
ENG
12:01
17-01-2021​

Answers

Answered by Prativa54321
1

Answer:

46 is the answer

Explanation:

please give me brainlyest ,,,,,,,,,,....

Similar questions