You are viewing a single comment's thread. Return to all comments →
Java Simple Solution:
public static int viralAdvertising(int n) { int start = 1; int countAdv = 0; int day = 5; while(start<=n){ int liked = day/2; countAdv = countAdv+liked; day = liked*3; start++; } return countAdv; }
Seems like cookies are disabled on this browser, please enable them to open this website
Viral Advertising
You are viewing a single comment's thread. Return to all comments →
Java Simple Solution: