您如何将int转换为int64_t [英] How do you convert int into int64_t

查看:507
本文介绍了您如何将int转换为int64_t的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在创建一个游戏,我想将Game Center集成到其中.我看过了,原来要提交的整数必须为int64_t.我正在使用的int是标准int.我如何将我的高分int转换为int64_t?

I am creating a game and I want to intergrate Game Center into it. I have looked and it turns out that the integer that you want to submit has to be int64_t. And the int that I am using is a standard int. how would I convert my high score int to an int64_t?

推荐答案

您可以尝试将int强制转换为int64_t:

You can try to cast the int to int64_t:

int a = 12345;
int64_t b = (int64_t)a;

这篇关于您如何将int转换为int64_t的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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