当前位置:网站首页>Consolidate -c operator
Consolidate -c operator
2022-07-01 11:58:00 【Jinan medical applet champion】
Foundation entry consolidation
#region Operator 071 The arithmetic Relationship Logic
// The arithmetic
int suan = 1;
int suan2 = 2;
int suan3 = suan + suan2;
Console.WriteLine(" Operator arithmetic operator addition calculation :{0}",suan3);
// Comparison operator == > <
// == Indicates that the results of the operation of the expressions on both sides are equal , Notice that there are two equal signs .
// such as 10 % 2 It's an expression . 0 Alone is an expression , Although only a number .
Console.WriteLine("10 Is it an even number ?!:"+ (10 % 2 ==0));
// For example, design 1 Expression . 5 Start divination at the third day of August in Xinsi year , The specific divination is as follows : The method of divination : number of years + Monthly number + days , Its sum is divided by eight , Mod , Divide by eight . Ren Yin Nian 3 Earth branch numbers , Lunar calendar 6 month , Digital 6, The third day of June .
// 3+6+3=12 % 8 = The result is false, How can I serve true?
Console.WriteLine(" Residual calculation results :"+(12 % 8 ==0.96));
// Logical operators
//【 example 2】 Judge 2017 Whether the year is a leap year .
// According to the title requirements , The judgment of leap year needs to meet one of two conditions , One is that the year can be 4 Integer but cannot be 100 Integers , One is that it can be 400 to be divisible by . The code is as follows .
Console.WriteLine(" Judge 2017 Whether the year is a leap year ?:"+((2017 % 4 ==0 && 2017 % 100 !=0 ) || (2017 % 400 ==0)));
Console.WriteLine(" Judge 2018 Whether the year is a leap year ?:" + ((2018 % 4 == 0 && 2018 % 100 != 0) || (2018 % 400 == 0)));
#endregioneffect

边栏推荐
- Golang des-cbc
- Harbor webhook from principle to construction
- Y48. Chapter III kubernetes from introduction to mastery -- pod status and probe (21)
- 内核同步机制
- 小米手机解BL锁教程
- Width and widthstep of iplimage
- Share the method of how to preview PSD format and PSD file thumbnail plug-in [easy to understand]
- Le semester manquant
- 邻接矩阵无向图(一) - 基本概念与C语言
- Can solo be accessed through IPv6?
猜你喜欢

使用set_handler过滤掉特定的SystemC Wraning &Error Message

Exposure: a white box photo post processing framework reading notes

Deep understanding of grpc part1

S7-1500PLC仿真
![[Maui] add click events for label, image and other controls](/img/d6/7ac9632681c970ed99c9e4d3934ddc.jpg)
[Maui] add click events for label, image and other controls

Software project management 9.2 Software project configuration management process

MQ-防止消息丢失及重复消费

CPI tutorial - asynchronous interface creation and use

redis配置环境变量

The Missing Semester
随机推荐
自组织是管理者和成员的双向奔赴
2022/6/30学习总结
Custom grpc plug-in
Compile and debug net6 source code
ABBIRB120工业机器人机械零点位置
redis中value/list
uniapp 使用 uni-upgrade-center
图的理论基础
JS date format conversion method
Golang des-cbc
GID: open vision proposes a comprehensive detection model knowledge distillation | CVPR 2021
Extended tree (I) - concept and C implementation
CPI tutorial - asynchronous interface creation and use
区间乘积的因子数之和——前缀和思想+定一移二
Explore the contour detection function findcontours() of OpenCV in detail with practical examples, and thoroughly understand the real role and meaning of each parameter and mode
NOV Schedule for . Net to display and organize appointments and recurring events
谈思生物直播—GENOVIS张洪妍抗体特异性酶切技术助力抗体药物结构表征
今天开户今天能买股票吗?在线开户是很安全么?
Joint Time-Frequency and Time Domain Learning for Speech Enhancement
如何看懂开发的查询语句