Tag:Octal number system

  • Multiple base and base conversion in JavaScript

    Time:2022-7-11

    Hexadecimal introduction JavaScriptThere are four decimal representation methods provided in: decimal, binary, hexadecimal, octal.For numeric literal quantities, different prefixes are mainly used to distinguish: Decimal:Value number0-9; No prefix. Binary:Value number0and1; prefix0bor0B。 Hexadecimal:Value number0-9anda-f; prefix0xor0X。 Octal (octal):Value number0-7; prefix0oor0O(ES6 regulation). It should be noted that browser support in non strict mode: if there is prefix 0 […]

  • Regular expression collation

    Time:2022-7-5

    Complete set of expressions character describe \ Marks the next character as a special character, or a literal character, or a backward reference, or an octal escape character. For example“n”Match character“n”。“\n”Match a newline character. Serial“\\”Match“\”And“\(”Then match“(”。 ^ Matches the start position of the input string. If the multiline property of regexp object is set, ^ […]

  • [‘1′,’2′,’3’]. Map (parseInt) results and causes, detailed explanation of parseInt parameters

    Time:2022-6-3

    The result is: [1, Nan, nan] for the following reasons [‘1′,’2′,’3’].map(parseInt)The code actually executed is: [‘1′,’2′,’3’].map((item,index)=>{ return parseInt(item,index) }) The returned values are: parseInt(‘1’,0) //1 parseInt(‘2’,1) //NaN parseInt(‘3’,2) //NaN First understand the map method The map () method creates a new array, and the result is the result returned after each element of the array […]

  • The fifth day of C language learning

    Time:2022-5-22

    C language //This is a comment \N this is line feed There should be a semicolon after each line of statement; Printf outputs the bracketed content as it is /** / multiline comment The main() main function is the beginning of everything %D displays a decimal integer Int integer decimal Numbers beginning with 0 are […]

  • Explain Linux file permissions

    Time:2022-1-13

    Linux file permissions Before going deeper, let’s understand the basic information of file permissions. First create an information file >$ touch new_file >$ ll new_file >$- rw-r — R — 1 root 0 April 23 22:59 NEW_ file File new_ File has the following three groups of permissions: RW -: the owner of the file. […]

  • Hex to octal

    Time:2021-12-20

    Problem description Given n hexadecimal positive integers, output their corresponding octal Input format The first line of input is a positive integer n (1 < = n < = 10) Next N lines, one for each line by 09,AThe string composed of F represents the hexadecimal positive integer to be converted, and the length of […]

  • Study hard go: 17 Explain 20 placeholders

    Time:2021-12-11

    Series articles: Learn go: 1 Learning lead Study hard go: 2 Environment construction Study hard go: 3 Environment construction – gomod learning Study hard go: 4 Variables and data types Study hard go: 5 Constants and operators Study hard go: 6 Process control Study hard go: 7 Built in collection array Study hard go: 8 […]

  • Java string format example

    Time:2021-9-2

    Always forget the Java string format specifier? Or maybe you never took the time to learn. This is a reference to the various signs you can use.Do you try to read and understand Java’s string format documents? I’ve found it almost impenetrable. Although it does contain all the information, the organization still has some shortcomings. […]

  • The usage of input output conversion specifier in C language

    Time:2021-6-9

    The usage of input output conversion specifier in C language This paper mainly introduces the usage of conversion specification in formatted input and output statements in C language printf sprintf fprintfConversion specifier for % [flags][width][.precision][length]specifier flags meaning – Align left + When the signed value is positive, a positive sign is added before the value; […]

  • In this paper, we understand the principle and conversion between system

    Time:2021-6-8

    The numbers we use in our life are all decimal, and binary is the most direct language that the machine can recognize. But binary is too big to record. So binary is usually converted to octal or hexadecimal. In our daily life, the number (decimal system) is between 0 ~ 9. Similarly, the range of […]

  • C language learning (1)

    Time:2021-4-30

    1、 Fundamentals of C language 1. Learning methods See more + knock more + think more 2. History of C language Machine code: 01 binary to write code, very difficult 10 + 11 operation   + —》 01001Assembly language: replacing sequences in machine code with mnemonics   + —》addB language1972: Design UNIX system and invented C language […]

  • Detailed explanation of output controller

    Time:2021-4-1

    Why use output controllers: We know that in the computer, data is stored in the form of binary in the computer, but the code composed of 01 can represent both data and instructions. It’s easy to misunderstand if we don’t use the output controller to become what we want. If the code composed of 01 […]