I have a file 

```
4 5 6 6
1 7 5 5 
7 0 2 1
7 8 0 6

```

and I would like to produce files that have random chosen rows from this file with reputation. So the outputs can be for instance:

```
4 5 6 6
1 7 5 5 
1 7 5 5
7 8 0 6

7 8 0 6
1 7 5 5 
1 7 5 5
7 8 0 6

```

I mean that some of the rows will be in the output more times, some of the rows zero times. Is it possible to produce a list of random numbers with reputation and according to it choose rows from input? Is it possible in awk or is some other language more appropriate?