当前位置:网站首页>Extract non duplicate integers
Extract non duplicate integers
2022-04-23 15:40:00 【Ye Ningxia Xin】
describe
Enter a int Type integer , Read right to left , Returns a new integer with no repeating numbers .
Ensure that the last bit of the input integer is not 0 .
Data range :1≤n≤10^8
Input description :
Enter a int Type integer
Output description :
Read right to left , Returns a new integer with no repeating numbers
Example 1
Input :9876673
Output :37689
a = int(input())
b = a[::-1]
list = []
for i in b:
if i in list:
continue
else:
list.append(i)
print(i,end='')
a[:-1] And a[::-1] difference
a[:-1] And a[::-1] difference _baybig The blog of -CSDN Blog _a[::-1]
版权声明
本文为[Ye Ningxia Xin]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204231534071517.html
边栏推荐
猜你喜欢

c语言---字符串+内存函数

Cookie&Session

Special analysis of China's digital technology in 2022
![[leetcode daily question] install fence](/img/4e/3ac23174f2b3ee867b45a2e748b872.png)
[leetcode daily question] install fence

Explanation 2 of redis database (redis high availability, persistence and performance management)

Mysql database explanation (IX)

木木一路走好呀

激活函数的优缺点和选择

Treatment of idempotency

Neodynamic Barcode Professional for WPF V11. 0
随机推荐
【backtrader源码解析18】yahoo.py 代码注释及解析(枯燥,对代码感兴趣,可以参考)
提取不重复的整数
Advantages, disadvantages and selection of activation function
Basic concepts of website construction and management
移动app测试如何进行?
Mobile finance (for personal use)
如果conda找不到想要安装的库怎么办PackagesNotFoundError: The following packages are not available from current
MultiTimer v2 重构版本 | 一款可无限扩展的软件定时器
【AI周报】英伟达用AI设计芯片;不完美的Transformer要克服自注意力的理论缺陷
大型互联网为什么禁止ip直连
T2 icloud calendar cannot be synchronized
2022年中国数字科技专题分析
自主作业智慧农场创新论坛
今日睡眠质量记录76分
多生成树MSTP的配置
What if the server is poisoned? How does the server prevent virus intrusion?
Connect PHP to MSSQL via PDO ODBC
Deeply learn the skills of parameter adjustment
山寨版归并【上】
删除字符串中出现次数最少的字符