Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Go 脚本记录说明 - Ray_YC's Blog #18

Open
lyc10031 opened this issue Sep 19, 2019 · 0 comments
Open

Go 脚本记录说明 - Ray_YC's Blog #18

lyc10031 opened this issue Sep 19, 2019 · 0 comments

Comments

@lyc10031
Copy link
Owner

https://lyc10031.github.io/2019/09/17/go-scripts.html

翻转一个整数 输入123,返回321;输入-321返回-123 输入的整数要求是一个 32bit 有符号数,如果反转后溢出,则输出 01234567891011func reverse(x int) (num int) { for x != 0 { num = num*10 + x%10 x = x / ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant