当前位置:网站首页>ISBN number
ISBN number
2022-07-03 23:56:00 【< WRM>】
#include<bits/stdc++.h>
using namespace std;
int main() {
string str;
cin >> str;
int a[10];
int pos = 0;
for (int i = 0; i < str.size(); i++) {
if (isdigit(str[i])) {
a[pos++] = str[i] - 48;
}
}
int sum = 0;
for (int i = 0; i < 9; i++) {
sum = sum + a[i] * (i + 1);
}
char x;
if (sum % 11 == 10) {
x = 'X';
} else {
x = sum % 11 + 48;
}
if (x == str[str.size() - 1]) {
printf("Right\n");
} else {
for (int i = 0; i < str.size() - 1; i++) {
cout << str[i];
}
printf("%c\n", x);
}
}
边栏推荐
- Live app source code, jump to links outside the station or jump to pages inside the platform
- Ningde times and BYD have refuted rumors one after another. Why does someone always want to harm domestic brands?
- Selenium library 4.5.0 keyword explanation (I)
- Solve the problem that the kaggle account registration does not display the verification code
- Gossip about redis source code 75
- Vscode regular match replace console log(.*)
- Gossip about redis source code 83
- Private project practice sharing populate joint query in mongoose makes the template unable to render - solve the error message: syntaxerror: unexpected token r in JSON at
- [BSP video tutorial] stm32h7 video tutorial phase 5: MDK topic, system introduction to MDK debugging, AC5, AC6 compilers, RTE development environment and the role of various configuration items (2022-
- Fudan 961 review
猜你喜欢

Zipper table in data warehouse (compressed storage)

Design of logic level conversion in high speed circuit

A method to solve Bert long text matching

Cgb2201 preparatory class evening self-study and lecture content

Analysis on the scale of China's smart health industry and prediction report on the investment trend of the 14th five year plan 2022-2028 Edition

How to write a good title of 10w+?

NLP Chinese corpus project: large scale Chinese natural language processing corpus

Fluent learning (5) GridView

Gorilla/mux framework (RK boot): add tracing Middleware

leetcode-43. String multiplication
随机推荐
[note] IPC traditional interprocess communication and binder interprocess communication principle
Pandaoxi's video
股票开户佣金最低的券商有哪些大家推荐一下,手机上开户安全吗
How to quickly build high availability of service discovery
Gossip about redis source code 79
The upload experience version of uniapp wechat applet enters the blank page for the first time, and the page data can be seen only after it is refreshed again
Make small tip
What is the difference between NFT, SFT and dnft? How to build NFT platform applications?
Selenium library 4.5.0 keyword explanation (4)
SQL data update
Collation of the most complete Chinese naturallanguageprocessing data sets, platforms and tools
Learning methods of zynq
Briefly understand the operation mode of developing NFT platform
Report on the construction and development mode and investment mode of sponge cities in China 2022-2028
C # basic knowledge (3)
ESP Arduino playing with peripherals (V) basic concept of interrupt and timer interrupt
Advanced C language - pointer 2 - knowledge points sorting
Double efficiency. Six easy-to-use pychar plug-ins are recommended
IO flow principle and classification
Gossip about redis source code 78