C ++中的无符号关键字 [英] Unsigned keyword in C++

查看:349
本文介绍了C ++中的无符号关键字的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

unsigned关键字是否默认为C ++中的数据类型?我试图写一个类的原型的函数:

Does the unsigned keyword default to a data type in C++? I am trying to write a function for a class for the prototype:

unsigned Rotate(unsigned object, int count)

但我真的没有得到什么未签名的意思。我认为这将像无符号整数或东西。感谢。

But I don't really get what unsigned means. I thought it would be like unsigned int or something. Thanks.

推荐答案

链接


其中一些类型可以使用signed,unsigned,short和long 。当这些类型修饰符中的一个单独使用时,假定int的数据类型为

Several of these types can be modified using the keywords signed, unsigned, short, and long. When one of these type modifiers is used by itself, a data type of int is assumed

这意味着你可以假定作者是使用整数。

This means that you can assume the author is using ints.

这篇关于C ++中的无符号关键字的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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