{"push_id":1333539891,"size":1,"distinct_size":1,"ref":"refs/heads/master","head":"02956d903e82fc57750034cf33be7ec7fce2832e","before":"eee046200d720107b75fe189163ff94696629b49","commits":[{"sha":"02956d903e82fc57750034cf33be7ec7fce2832e","author":{"name":"Saumya Priya","email":"04c07f418482110b525de43accb39989cf9e7ff7@gmail.com"},"message":"https://leetcode.com/problems/rotate-function/\n\nAccording to the problem statement\r\nF(0) = (0A) + (1B) + (2C) + (3D) + (4E)\r\nF(1) = (4A) + (0B) + (1C) + (2D) + (3E)\r\nF(2) = (3A) + (4B) + (0C) + (1D) + (2*E)\r\n\r\nThis problem at a glance seem like a difficult problem. I am not very strong in mathematics, so this is how I visualize this problem\r\n\r\nWe can construct F(1) from F(0) by two step:\r\nStep 1. taking away one count of each coin from F(0), this is done by subtracting \"sum\" from \"iteration\" in the code below\r\nafter step 1 F(0) = (-1A) + (0B) + (1C) + (2D) + (3*E)\r\n\r\nStep 2. Add n times the element which didn't contributed in F(0), which is A. This is done by adding \"A[j-1]len\" in the code below.\r\nafter step 2 F(0) = (4A) + (0B) + (1C) + (2D) + (3E)\r\n\r\nAt this point F(0) can be considered as F(1) and F(2) to F(4) can be constructed by repeating the above steps.","distinct":true,"url":"https://api.github.com/repos/findsaumyahere/LeetCode/commits/02956d903e82fc57750034cf33be7ec7fce2832e"}]}
{"actor":{"display_login":"findsaumyahere"}}