mirror of https://github.com/grafana/grafana.git
				
				
				
			
		
			
	
	
		
			18 lines
		
	
	
		
			228 B
		
	
	
	
		
			Go
		
	
	
	
		
		
			
		
	
	
			18 lines
		
	
	
		
			228 B
		
	
	
	
		
			Go
		
	
	
	
|  | package util | ||
|  | 
 | ||
|  | // MaxInt returns the larger of x or y.
 | ||
|  | func MaxInt(x, y int) int { | ||
|  | 	if x < y { | ||
|  | 		return y | ||
|  | 	} | ||
|  | 	return x | ||
|  | } | ||
|  | 
 | ||
|  | // MinInt returns the smaller of x or y.
 | ||
|  | func MinInt(x, y int) int { | ||
|  | 	if x > y { | ||
|  | 		return y | ||
|  | 	} | ||
|  | 	return x | ||
|  | } |