Driver Code
public static void Main ( String [ ] args ) { int [ ] pages = { 7 , 0 , 1 , 2 , 0 , 3 , 0 , 4 , 2 , 3 , 0 , 3 , 2 } ; int capacity = 4 ; Console . WriteLine ( pageFaults ( pages , pages . Length , capacity ) ) ; } }