Skip to content

Instantly share code, notes, and snippets.

View kerhbal's full-sized avatar

kerhbal

  • Toronto
View GitHub Profile
@kerhbal
kerhbal / MyCowQuestion.java
Created August 2, 2021 15:56
Assignment-2021-08-02
package ca.bytetube._11_recursion;
public class MyCowQuestion {
public static int myCowQuestion1(int n){
if (n <= 1) return n;
int[] arr = new int[n + 1];
arr[1] = 1;
arr[2] = 2;
arr[3] = 3;
arr[4] = 4;