
【入门1】顺序结构
dllglvzhenfeng
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
P1425 小鱼的游泳时间(python3实现)
https://www.luogu.com.cn/problem/P1425 """ P1425 小鱼的游泳时间 https://www.luogu.com.cn/problem/P1425 """ a,b,c,d=list(map(int,input().split())) delta=(60*c+d)-(60*a+b) e=delta//60 f=delta%60 print(e,end=' ') print(f)原创 2022-01-26 21:48:40 · 1047 阅读 · 1 评论 -
P3954 [NOIP2017 普及组] 成绩(python3实现)
https://www.luogu.com.cn/problem/P3954 """ P3954 [NOIP2017 普及组] 成绩 https://www.luogu.com.cn/problem/P3954 """ a,b,c=list(map(int,input().split())) ans=a*2//10+b*3//10+c*5//10 print(ans)原创 2022-01-26 23:50:12 · 290 阅读 · 0 评论 -
P2181 对角线(python3实现)
https://www.luogu.com.cn/problem/P2181 """ P2181 对角线 https://www.luogu.com.cn/problem/P2181 """ n=int(input()) ans=n*(n-1)//2*(n-2)//3*(n-3)//4 print(ans)原创 2022-01-29 10:59:50 · 493 阅读 · 0 评论 -
P5708 【深基2.习2】三角形面积(python3实现)
【深基2.习2】三角形面积 - 洛谷 """ P5708 【深基2.习2】三角形面积 https://www.luogu.com.cn/problem/P5708 """ import math a,b,c=map(float,input().split()) p=(a+b+c)/2 ans=math.sqrt(p*(p-a)*(p-b)*(p-c)) print("%.1f"%ans)原创 2022-01-30 21:27:28 · 546 阅读 · 0 评论 -
P5706 【深基2.例8】再分肥宅水(python3实现)
https://www.luogu.com.cn/problem/P5706 """ P5706 【深基2.例8】再分肥宅水 https://www.luogu.com.cn/problem/P5706 """ #t=input() #n=int(input()) t,n=list(input().split()) t=float(t) n=int(n) #print(t) #print(n) ans01=t/n ans02=n*2 print("%.3f" % ans01) print原创 2022-01-26 20:14:59 · 876 阅读 · 1 评论 -
P5703 【深基2.例5】苹果采购(python3实现)
https://www.luogu.com.cn/problem/P5703 """ P5703 【深基2.例5】苹果采购( python3实现 ) https://www.luogu.com.cn/problem/P5703 """ t,n=map(int,input().split()) print(t*n)原创 2022-01-25 18:56:40 · 471 阅读 · 0 评论 -
P5703 【深基2.例5】苹果采购(python3实现)--2022.01.29
https://www.luogu.com.cn/problem/P5703 """ P5703 【深基2.例5】苹果采购 https://www.luogu.com.cn/problem/P5703 """ m,n=map(int,input().split()) ans=m*n print(ans)原创 2022-01-29 16:43:55 · 410 阅读 · 0 评论 -
P5705 【深基2.例7】数字反转(python3实现)方法二
https://www.luogu.com.cn/problem/P5705 """ P5705 【深基2.例7】数字反转(python3实现)方法二 https://www.luogu.com.cn/problem/P5705 """ a=input() p=list(a) #print(p) print(p[4],end='') print(p[3],end='') print(p[2],end='') print(p[1],end='') print(p[0],end='')原创 2022-01-25 19:49:11 · 954 阅读 · 0 评论 -
P5704 【深基2.例6】字母转换(python实现)
https://www.luogu.com.cn/problem/P5704 """ P5704 【深基2.例6】字母转换 https://www.luogu.com.cn/problem/P5704 """ #ch=map(chr,input().split()) ch=input() print(ch.upper())原创 2022-01-25 19:06:51 · 515 阅读 · 0 评论 -
P5709 【深基2.习6】Apples Prologue 苹果和虫子(python3实现)
https://www.luogu.com.cn/problem/solution/P5709 """ P5709 【深基2.习6】Apples Prologue 苹果和虫子 https://www.luogu.com.cn/problem/solution/P5709 """ #import sys m,t,s=list( map(int,input().split())) if t==0: print(0) #sys.exit(0) el原创 2022-01-29 11:28:38 · 1020 阅读 · 0 评论 -
P5703 【深基2.例5】苹果采购(scratch实现)
【深基2.例5】苹果采购 - 洛谷 scratch2实现 scratch3实现 python3代码: """ P5703 【深基2.例5】苹果采购 https://www.luogu.com.cn/problem/P5703 """ m,n=map(int,input().split()) ans=m*n print( ans ) C++代码: /* P5703 【深基2.例5】苹果采购 https://www.luogu.com.cn/problem...原创 2022-02-12 16:50:14 · 349 阅读 · 0 评论 -
P5707 【深基2.例12】上学迟到(python3实现)
https://www.luogu.com.cn/problem/P5707 """ P5707 【深基2.例12】上学迟到 https://www.luogu.com.cn/problem/P5707 """ import math s,v=map(int,input().split()) n=8*60+24*60 t=math.ceil(s/v)+10 n=n-t if n>=24*60: n-=24*60 b=n%60 a=n//60 if a&原创 2022-01-29 14:56:19 · 499 阅读 · 0 评论 -
P5705 【深基2.例7】数字反转(python3实现)方法一
https://www.luogu.com.cn/problem/P5705 """ P5705 【深基2.例7】数字反转(python3实现)方法一 https://www.luogu.com.cn/problem/P5705 """ p=float(input()) q=int(p*10) a=q//1000 b=q//100%10 c=q//10%10 d=q%10 print("%d"%d,end='.') print(c,end='') print(b,end='') prin原创 2022-01-25 19:38:11 · 875 阅读 · 0 评论 -
P5704 【深基2.例6】字母转换(python3实现)-2022.01.29
https://www.luogu.com.cn/problem/P5704 """ P5704 【深基2.例6】字母转换 https://www.luogu.com.cn/problem/P5704 """ q=input() Q=q.upper() #print(q.upper()) print(Q)原创 2022-01-29 16:57:32 · 270 阅读 · 0 评论 -
P5706 【深基2.例8】再分肥宅水--2022.02.13
【深基2.例8】再分肥宅水 - 洛谷 C++代码: /* P5706 【深基2.例8】再分肥宅水--2022.02.13 https://www.luogu.com.cn/problem/P5706 */ #include <bits/stdc++.h> #include<stdio.h> using namespace std; int main() { int n,ans02; double t,ans01; cin>>t>>n; a原创 2022-02-13 18:47:25 · 750 阅读 · 0 评论