11 lines
		
	
	
	
		
			144 B
		
	
	
	
		
			Go
		
	
	
	
	
	
		
		
			
		
	
	
			11 lines
		
	
	
	
		
			144 B
		
	
	
	
		
			Go
		
	
	
	
	
	
| 
								 | 
							
								package files
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								import "math/rand"
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								func PickRandomFile() string {
							 | 
						||
| 
								 | 
							
									files := GetCandidates()
							 | 
						||
| 
								 | 
							
									idx := rand.Intn(len(files))
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
									return files[idx]
							 | 
						||
| 
								 | 
							
								}
							 |