Counting And Sampling Paths In Graphs