我不打朋友圈
我不打朋友圈
全部文章
题解
归档
标签
去牛客网
登录
/
注册
我不打朋友圈的博客
全部文章
/ 题解
(共249篇)
题解 | #明明的随机数#
来自专栏
import java.util.; import java.io.; public class Main{ public static void main(String[] args)throws IOException{ BufferedReader in = new BufferedReade...
Java
2022-01-01
0
476
题解 | #计算某字符出现次数#
来自专栏
import java.util.; import java.io.; public class Main{ public static void main(String[]args)throws IOException{ BufferedReader in = new BufferedReade...
Java
2022-01-01
0
433
题解 | #剪绳子(进阶版)#
来自专栏
import java.util.*; public class Solution { final int MOD = 998244353; long pow(long a, long n){ long ans = 1; while(n>0){ if(n%2 =...
Java
2022-01-01
0
528
题解 | #左旋转字符串#
来自专栏
public class Solution { public String LeftRotateString(String str,int n) { if(str == null || str.length() == 0 ) return str; n %= str.length(); if(n =...
Java
2022-01-01
0
373
题解 | #剪绳子#
来自专栏
public class Solution{ public int cutRope(int target){ if(target == 2 || target == 3) return target - 1; int result = 1; while(target > 4){ target ...
Java
2022-01-01
0
417
题解 | #剪绳子#
来自专栏
public class Solution { public int cutRope(int target) { if (target == 2 || target == 3) return target - 1; int res = 1; while (target > 4) { //如果t...
Java
2022-01-01
0
293
题解 | #在二叉树中找到两个节点的最近公共祖先#
来自专栏
import java.util.; public class Solution{ public ArrayList<ArrayList> FindContinuousSequence(int sum){ ArrayList<ArrayList> result = new A...
Java
2022-01-01
0
304
题解 | #在二叉树中找到两个节点的最近公共祖先#
来自专栏
import java.util.ArrayList; public class Solution { public ArrayList<ArrayList > FindContinuousSequence(int sum) { ArrayList<ArrayList> re...
Java
2022-01-01
0
425
题解 | #在二叉树中找到两个节点的最近公共祖先#
来自专栏
import java.util.ArrayList; public class Solution { public ArrayList<ArrayList > FindContinuousSequence(int sum) { ArrayList<ArrayList> re...
Java
2022-01-01
0
351
题解 | #在二叉树中找到两个节点的最近公共祖先#
来自专栏
//主要解决指针移动问题就好了 public class Solution{ public int GetUglyNumber_Solution(int index){ if(index <= 6) return index; int p1 = 0; int p2 = 0; int p3 = ...
Java
2022-01-01
0
320
首页
上一页
12
13
14
15
16
17
18
19
20
21
下一页
末页