Java中的Double Greater Than(>>)? [英] Double Greater Than Sign (>>) in Java?

查看:261
本文介绍了Java中的Double Greater Than(>>)?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

>> 符号在Java中的含义是什么?我以前从未见过它,但今天遇到它。我尝试在Google上搜索它,但没有找到任何有用的东西。

What does the >> sign mean in Java? I had never seen it used before but came across it today. I tried searching for it on Google, but didn't find anything useful.

推荐答案

这是位移操作符。 文档


签名的左移运算符<<
向左移位位模式,
用带符号的右移运算符>>
向右移位位模式。
位模式由左侧
操作数给出,以及由右侧操作数移位的位置

无符号右移操作符
>>>将零移动到最左边的
位置,而>>后最左边的位置
取决于符号扩展。

The signed left shift operator "<<" shifts a bit pattern to the left, and the signed right shift operator ">>" shifts a bit pattern to the right. The bit pattern is given by the left-hand operand, and the number of positions to shift by the right-hand operand. The unsigned right shift operator ">>>" shifts a zero into the leftmost position, while the leftmost position after ">>" depends on sign extension.

这篇关于Java中的Double Greater Than(&gt;&gt;)?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆