当前位置:网站首页>Calculate rectangular area
Calculate rectangular area
2022-06-29 02:18:00 【Long street 395】
describe
The user enters the length and width of the rectangle , Calculate its area and output .
a = eval(input()) # Enter an integer string , Convert to integer ; Enter the floating-point number string , Convert to floating point
b = float(input()) # Enter integer and floating point numbers , Are converted to floating point numbers
c = int(input()) # Only integer inputs are accepted , The output is an integer
#eval() and float() Functions can put input() The numeric string received by the function is converted to numeric type
# example :float('3.14') The result is numerical 3.14
#int() The function can convert an integer string to an integer
# example :int('5') The result is numerical 5
Input format
Enter a number on the first line , Represents the length of the rectangle
Enter a number on the second line , Represents the width of the rectangle
( Input usage input(), Don't add additional tips )
Output format
Area of output rectangle , Unlimited decimal places
Example 1
Input :
3.1415926
5.88
Output :
18.472564488
Example 2
Input :
5
8
Output :
40 Explain :
# User input length and width , Calculate the area of the rectangle
width = eval(input()) # Input width
length = eval(input()) # Input length
area = width * length # Calculated area
print(area) # Output area
边栏推荐
- 微信运动自动点赞
- 如何成为一名高级数字 IC 设计工程师(6-7)数字 IC 验证篇:DEBUG 技巧
- 大智慧手机股票开户哪个券商更安全更方便?
- 利用kubernetes资源锁完成自己的HA应用
- What is the dry goods microservice architecture? What are the advantages and disadvantages?
- 网上联系客户经理办理炒股开户安全吗?
- Koa quick start
- The linkedhashset set makes the elements orderly without repetition
- 【Redis】List类型
- Blog publishing test 3
猜你喜欢
![[redis] list type](/img/c7/adec2aaea50d69a0aed95bfe683b9e.png)
[redis] list type

KOA Quick Start

目标检测——ADAS实战
![[redis] key hierarchy](/img/ab/a5d3bb61b4571966d0f47037af4f41.png)
[redis] key hierarchy

三角函数计算
![[redis] set type](/img/97/0a83016e89316849c01072044f2124.png)
[redis] set type
![[understanding of opportunity -33]: seeing is not necessarily true. Most of the time,](/img/60/703a5bc3038d28bcf812415032f240.jpg)
[understanding of opportunity -33]: seeing is not necessarily true. Most of the time, "seeing is false"
![[redis] sortedset type](/img/7f/f5f1aa603c8994b669d52a435fed7e.png)
[redis] sortedset type

Finally got the byte offer. The 25-year-old inexperienced experience in software testing is written to you who are still confused

Crawler exercise (IV) -- IP address problem
随机推荐
Is there any risk in opening an account for Dongfang fortune stock? Is it safe for Dongfang fortune to open an account
利用kubernetes资源锁完成自己的HA应用
东方财富股票开户是会有什么风险吗?东方财富开户安全吗
[从零开始学习FPGA编程-49]:视野篇 - 芯片是如何被设计出来的?
计算矩形面积
Junior final exam
如何成为一名高级数字 IC 设计工程师(6-5)数字 IC 验证篇:覆盖率收集
如何成为一名高级数字 IC 设计工程师(6-7)数字 IC 验证篇:DEBUG 技巧
Zhongyi technology resumed the review status of the gem IPO, and xuxiaofei no longer acted as a practicing lawyer
Oculusrifts and unity UI interaction (1) - Overview
如何成为一名高级数字 IC 设计工程师(4-2)脚本篇:Verilog HDL 代码实现的文件读写操作
2022.02.15
Why install an SSL certificate on a web site?
[机缘参悟-33]:眼见不一定为实,大多数时候“眼见为虚”
Eliminate the hover effect when the button is disabled
MySQL的下载和安装
瀑布型项目管理最常用的10个小工具,可以自由搭建使用
【学习笔记】子集和问题
How to become a senior digital IC Design Engineer (6-5) digital IC Verification: coverage collection
Utiliser kubernets Resource Lock pour compléter son application ha