题目: 题解:
class Solution {
public:int getSteps(int curr, long n) {int steps 0;long first curr;long last curr;while (first < n) {steps min(last, n) - first 1;first first * 10;last last * 10 9;}return steps;}int findKthNum…
1.题目: 解析: (1)这里主要是处理细节:超过1千克向上取整,怎么处理; 这是原理: 代码: public static void main(String[] args) {Scanner in new Scanner(System.in);do…