题解列表

筛选

三角形最佳路径问题

摘要:参考代码:public static void main(String[] args) {     Scanner sc = new Scanner(System.in);     int n =……

简易求解最大公约数和最小公倍数

摘要:解题思路:这段代码的主要目的是求解两个整数的最大公约数和最小公倍数。1. 最大公约数(Greatest Common Divisor,GCD):   - 首先,通过`da`函数计算最大公约数。   -……

2869: 字符串最大跨距

摘要:解题思路:注意事项:参考代码:S, S1, S2 = map(str, input().split(",")) if S.find(S1) == -1 or S.find(S2) == -1:  ……

2870: 单词翻转

摘要:解题思路:注意事项:参考代码:s = input().split() arr = [] for i in s:     arr.append(i[::-1]) print(" ".join(a……

2871: 单词倒排

摘要:解题思路:注意事项:参考代码:print(" ".join(input().split()[::-1]))……