CodingA string is a data type, but a particular string is a coding problem.Because a computer can only handle numbers, if you are working with text, you must convert the text to a number before processing it. The oldest computer was designed with 8
I. Wide character Introduction
First of all, what is ASCII, ASCII is an encoding standard used to represent English characters. Each ASCII character occupies 1 byte. Therefore, the maximum number of characters that can be represented by ASCII
First, let's briefly talk about the history. The ASCII code was first developed by Americans. What is it? We know that the computer only knows 0 and 1. If we want the computer to recognize characters other than 01, for example, 'A', we must first
Instance
Returns the ASCII value of "H":
"; Echo ord (" Hello ")." ";? >
Definition and usage
The Ord () function returns the ASCII value of the first character in a string.
Grammar
Ord (String)
Parameter description
string is required. The string
/** read-only variables and constants const READ-only const int A;int const a;//are equivalent to the above line of code, all representing a constant shape number. int *const A;//const has a "left associative", that is, a const modifier *, then, it
itoa
Function: Converts an integer to a string
Usage: char *itoa (int value, char *string, int radix);
Explanation: ITOA is the abbreviation for the English Integer to array, which converts an int integer to a string and saves the value in an array
Python module introduction-binascii: Binary and ASCII conversion and other hexadecimal conversion2012-08-01 magnet
# Undertake software automation implementation, training, and other gtalk: ouyangchongwu # gmail.com qq 37391319# Copyright. For
ASCII code and Chinese characters in-machine code:In doing Hdoj 2030 Chinese character statistics in the discussion area to see the landlord Post said that the ASCII code value of Chinese characters is negative. But the ASCII code in the book range
1. ASCII
Returns the decimal number corresponding to the specified character;
Sql> Select ASCII (a) a,ascii (a) a,ascii (0) Zero,ascii () space from dual;
A A ZERO space
--------- --------- --------- ---------
65 97 48 32
2. CHR gives the
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.