陈教主的三角形(Java)
摘要:解题思路:注意事项:参考代码:import java.util.Scanner;
public class Main {
public static void main(String[] a……
列表注意还原为空列表
摘要:解题思路:注意事项:参考代码:while True: a,b,c=map(int,input().split()) d=[a,b,c] xx=sorted(d) if xx[0……
陈教主的三角形-题解(C++代码,一个不等式就可以判断)
摘要:解题思路:任意两边之和大于第三边 或者 任意两边之差小于第三边。满足次条件,则此三边可以围成三角形。注意事项:记住!任意两边之和大于第三边就已经意味着任意两边之差小于第三边,所以两个条件判断一个即……
陈教主的三角形-50%错误的,有可能是把判断的逻辑搞混了
摘要: #include
int main(void)
{
int a = 0, b = 0, c = 0;
while (EOF != sc……
陈教主的三角形-题解(C++代码)
摘要:利用三角形三边关系判断是否为三角形
```cpp
#include
using namespace std;
int main()
{
int a_int, b_int, c……
陈教主的三角形-题解(C++代码)
摘要:```cpp
#include
using namespace std;
int main()
{
int a, b, c;
while (cin>>a>>b>>c)
{
c……
陈教主的三角形-题解(C语言代码)
摘要: //1387多行测试数据,每行包含三个整数a、b、c(0= b && a >= c)
triangle(a, b, c);
else if (b >= a && ……