- A patient needs rehabilitation within next N days(numbered from 0 to N-1). The rehabilitation consists of X sessions. For every rehabilitation session,other than the last one,the next session is exactly Y days later.
You are given an array A of N integers listing the costs of the individual rehabilitation sessions on the N days: that is rehabilitation on the kth day costs A[k]. Write a function def solution(A,X,Y) that given the array A and the two integers X and Y returns the minimum cost of rehabilitation.
In this Question i was able to pass 2/3 public test cases and in 2nd one 3/4 public test cases..........
2nd Question was fully on the concept of graph theory and the minimum time to traverse the given graphs.