avatar
Java练习题 10# Java - 爪哇娇娃
u*s
1
Q1. What's the difference between process and thread?
Q2. What's the difference between Runnable and Callable?
Q3. What's the difference between when use synchronized method/block and
when use ReentrantLock
Q4. How to achieve wait/notify/notifyAll using java.util.concurrent package?
Q5. What is serialVersionUID? what is it for?
avatar
g*e
2
请问你这些题目都是在哪找的,谢谢

package?

【在 u****s 的大作中提到】
: Q1. What's the difference between process and thread?
: Q2. What's the difference between Runnable and Callable?
: Q3. What's the difference between when use synchronized method/block and
: when use ReentrantLock
: Q4. How to achieve wait/notify/notifyAll using java.util.concurrent package?
: Q5. What is serialVersionUID? what is it for?

avatar
s*8
3
求标准答案
avatar
g*e
4
这几个问题面试很常见吧,google一下到处都是

【在 s***8 的大作中提到】
: 求标准答案
avatar
q*u
5
好题, 我没有google, 自己裸答了,请包含指正一下

Q1. What's the difference between process and thread?
process is expensive, traditionally, doesn't share memory;
thread can be understood as a light weight process, can share memory
with
each other;
Q2. What's the difference between Runnable and Callable?
Callable can return value?
Callable can throw an exception?
Q3. What's the difference between when use synchronized method/block and
ReentrantLock can have multiple locks, more flexible than synchronized

【在 u****s 的大作中提到】
: Q1. What's the difference between process and thread?
: Q2. What's the difference between Runnable and Callable?
: Q3. What's the difference between when use synchronized method/block and
: when use ReentrantLock
: Q4. How to achieve wait/notify/notifyAll using java.util.concurrent package?
: Q5. What is serialVersionUID? what is it for?

avatar
q*u
6
感觉很害怕因为面java的时候突然冒出process来,这个好像很难从java这里来讲吧?

package?

【在 u****s 的大作中提到】
: Q1. What's the difference between process and thread?
: Q2. What's the difference between Runnable and Callable?
: Q3. What's the difference between when use synchronized method/block and
: when use ReentrantLock
: Q4. How to achieve wait/notify/notifyAll using java.util.concurrent package?
: Q5. What is serialVersionUID? what is it for?

avatar
u*s
7
有些是面试/考试的时候遇到的,有些是自己想的

【在 g**e 的大作中提到】
: 请问你这些题目都是在哪找的,谢谢
:
: package?

相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。