leetCode 932 Beautiful Array(分治)

题目连接 LeetCode 932java 分析 分治,将偶数和奇数分开就行了web code class Solution { public int[] beautifulArray(int N) { if(N==1)return new int[]{1}; else if(N ==2)return new int[]{2,1}; int
相关文章
相关标签/搜索