mirror of
				https://gitee.com/coder-xiaomo/leetcode-problemset
				synced 2025-11-04 11:43:12 +08:00 
			
		
		
		
	
		
			
				
	
	
		
			17 lines
		
	
	
		
			416 B
		
	
	
	
		
			HTML
		
	
	
	
	
	
			
		
		
	
	
			17 lines
		
	
	
		
			416 B
		
	
	
	
		
			HTML
		
	
	
	
	
	
<p>输入数字 <code>n</code>,按顺序打印出从 1 到最大的 n 位十进制数。比如输入 3,则打印出 1、2、3 一直到最大的 3 位数 999。</p>
 | 
						||
 | 
						||
<p><strong>示例 1:</strong></p>
 | 
						||
 | 
						||
<pre><strong>输入:</strong> n = 1
 | 
						||
<strong>输出:</strong> [1,2,3,4,5,6,7,8,9]
 | 
						||
</pre>
 | 
						||
 | 
						||
<p> </p>
 | 
						||
 | 
						||
<p>说明:</p>
 | 
						||
 | 
						||
<ul>
 | 
						||
	<li>用返回一个整数列表来代替打印</li>
 | 
						||
	<li>n 为正整数</li>
 | 
						||
</ul>
 |