当前位置:网站首页>父爱的表达方式
父爱的表达方式
2022-06-25 06:33:00 【grace.free】
2022年6月20日 星期一
诸葛十三和李大明白像往常一样来到公司上班。
由于来公司早,不用那么快投入工作。
于是两个人发生了以下有趣对话。
李:早呀!
十三:早!
李:真xx的热!
十三:是呀,空调没开吧?
李:估计是没开呢。
李:哎,朋友圈全是一些秀孝顺的。
十三:什么意思?
李:那句话怎么说来着,世间孝子千千万,朋友圈占了一大半。
十三:哈哈,还得是李大明白。
李:哈哈,开个玩笑。昨天我都没给家里打电话,我爸给我打了一个电话。
十三:你这是要造反呀!
李:哈哈,不敢不敢。
李:其实说朋友圈那些假孝顺也是不对的, 每个家庭都有自己的相处模式。
我家的相处模式可能就是偶尔打个电话,其实也不会聊很久,聊几句,近期没有什么事儿聊天就结束了。
十三:是呀,我一般一个星期给家里打一次电话,但是我姐基本每天打一次。
李:这个时候体现出来女儿的好处了吧。
十三:是的呀。
李:有些家庭可能比较open,相处模式比较先进,或者说他们更像短视频或者电视剧里那些家庭,
他们可以跟父母谈天说地,每天都可以与父母分享自己遇到的一些人和事儿。
李:一种爱是不用说“我爱你”的,另一种是“爱就大声说出来”。
十三:是的,没有对错,都是爱,都是伟大的爱。
李:这让我想到了一个Java知识点
十三:嗯嗯?说来听听
李:Java里有一个运算符 “+=”(当然还有"-="等)
+= 操作符会进行隐式自动类型转换,比如以下代码:
package base;
/** * @author 木子的昼夜编程 */
public class Test {
public static void main(String[] args) {
byte a = 100;
byte b = 100;
b+=a;
System.out.println(b);
}
}
编译后其实会变成这个样子:
//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//
package base;
public class Test {
public Test() {
}
public static void main(String[] args) {
byte a = 100;
byte b = 100;
byte b = (byte)(b + a);
System.out.println(b);
}
}
可以看到b+a被强转成byte了。
我们用Javap看一下idea生成的字节码 :
课外知识 : int强转byte、int强转short、int强转char,对应的指令是:i2b、i2s、i2c
这个“+=“就很像我们说的第一种爱,他默默地为我们做了一些事(类型转换),他可能会偷偷在你的出远门的行李里边夹一些钱,嘱咐你出门注意安全,钱省着点儿花,想家了就常回来看看。
我们也会偶尔这样写:
package base;
/** * @author 木子的昼夜编程 */
public class Test {
public static void main(String[] args) {
byte a = 100;
byte b = 100;
b = b+a;
System.out.println(b);
}
}
这里编译会报错:
这个很像我们所说的第二种爱,爱就直接说(直接告诉你类型错误,你自己改了),你如果要出远门,他会直接给你说,
给你微信转了点儿钱,收一下,出门该花花,混不好了回来,
多你一张嘴还是可以承担起的。
我的父母可能是第一种,虽然家里没什么钱,每次上学出门都会尽可能给我多带一些钱。他们经常的叮嘱就那几句话:
别不舍得吃好的,买箱牛奶放家里喝。
多买几身衣服,别舍不得买。
天热了该开空调就开空调,别舍不得开。
跟同事好好相处别闹别扭。
家里挺好的,不用担心。
十三:是呀,父母这辈子就一个愿望,你过得好,过得比他们好。
李:疫情应该快结束了,等结束了回家看看吧。
十三:是呀,好久没回家了。
彩蛋:
上边我们看到了b+=a的字节码,我们从中可以了解,+=会被分成多步操作,所以他不是线程安全的,有一些面试官喜欢问这个是不是线程安全的,为什么不是线程安全的。你仔细看看我上边那张图,大概说一下应该就能过了这个面试题。
边栏推荐
- Period to string [repeat] - period to string [duplicate]
- Missing libgmp-10 dll - libgmp-10. dll is missing
- Drosophila played VR and entered nature. It was found that there were attention mechanisms and working memory. The insect brain was no worse than that of mammals
- JS dynamic table creation
- What does cardinality mean in set
- DNS domain name system
- Analysis on the output, market scale and development status of China's children's furniture industry in 2020 and the competition pattern of children's furniture enterprises [figure]
- Go language library management restful API development practice
- Gb28181 protocol -- timing
- Leetcode 2163. Minimum difference of sum after element deletion
猜你喜欢
Drosophila played VR and entered nature. It was found that there were attention mechanisms and working memory. The insect brain was no worse than that of mammals
ACWING2013. 三条线
2022 AI trend 8 forecast!
Analysis of China's food cold chain logistics, output of quick-frozen noodles and rice products and operation of major enterprises in 2021 [figure]
Analysis on the output, market scale and development status of China's children's furniture industry in 2020 and the competition pattern of children's furniture enterprises [figure]
Power representation in go language
[轻松学会shell编程]-5、计划任务
Understand what MSS is
有能力的人从不抱怨大环境!
Kubernetes core components etcd details
随机推荐
[200 opencv routines of youcans] 104 Motion blur degradation model
What is cloud primordial?
Sophomores majoring in mechanics build a manipulator by hand -- full of compromise
Derivation of sin (a+b) =sina*cosb+sinb*cosa
How to chain multiple different InputStreams into one InputStream
Comparison test of mono 120W high power class D power amplifier chip cs8683-tpa3116
R & D thinking 07 - embedded intelligent product safety certification required
DataX tutorial (10) - hot plug principle of dataX plug-in
[no title] dream notes 2022-02-20
Unity获取资源路径
PHP converts strings to hex and hex to string - PHP convert string to hex and hex to string
Acwing2013. three lines
Drosophila played VR and entered nature. It was found that there were attention mechanisms and working memory. The insect brain was no worse than that of mammals
Explain @builder usage
Zero foundation wants to learn web security, how to get started?
Bcrypt password encryption kalrry
聚类和分类的最基本区别。
keil debug查看变量提示not in scope
Cs5092 5V USB input boost two section lithium battery charging management IC, SOT23-6 miniature package
How to realize hierarchical management of application and hardware in embedded projects