R Under development (unstable) (2024-01-23 r85822 ucrt) -- "Unsuffered Consequences" Copyright (C) 2024 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > message("TESTING: ASCII...") TESTING: ASCII... > > library("R.oo") Loading required package: R.methodsS3 R.methodsS3 v1.8.2 (2022-06-13 22:00:14 UTC) successfully loaded. See ?R.methodsS3 for help. R.oo v1.26.0 successfully loaded. See ?R.oo for help. Attaching package: 'R.oo' The following object is masked from 'package:R.methodsS3': throw The following objects are masked from 'package:methods': getClasses, getMethods The following objects are masked from 'package:base': attach, detach, load, save > > ## Display ASCII table > print(R.oo::ASCII) [1] "" "\001" "\002" "\003" "\004" "\005" "\006" "\a" "\b" "\t" [11] "\n" "\v" "\f" "\r" "\016" "\017" "\020" "\021" "\022" "\023" [21] "\024" "\025" "\026" "\027" "\030" "\031" "\032" "\033" "\034" "\035" [31] "\036" "\037" " " "!" "\"" "#" "$" "%" "&" "'" [41] "(" ")" "*" "+" "," "-" "." "/" "0" "1" [51] "2" "3" "4" "5" "6" "7" "8" "9" ":" ";" [61] "<" "=" ">" "?" "@" "A" "B" "C" "D" "E" [71] "F" "G" "H" "I" "J" "K" "L" "M" "N" "O" [81] "P" "Q" "R" "S" "T" "U" "V" "W" "X" "Y" [91] "Z" "[" "\\" "]" "^" "_" "`" "a" "b" "c" [101] "d" "e" "f" "g" "h" "i" "j" "k" "l" "m" [111] "n" "o" "p" "q" "r" "s" "t" "u" "v" "w" [121] "x" "y" "z" "{" "|" "}" "~" "\177" "\x80" "\x81" [131] "\x82" "\x83" "\x84" "\x85" "\x86" "\x87" "\x88" "\x89" "\x8a" "\x8b" [141] "\x8c" "\x8d" "\x8e" "\x8f" "\x90" "\x91" "\x92" "\x93" "\x94" "\x95" [151] "\x96" "\x97" "\x98" "\x99" "\x9a" "\x9b" "\x9c" "\x9d" "\x9e" "\x9f" [161] "\xa0" "\xa1" "\xa2" "\xa3" "\xa4" "\xa5" "\xa6" "\xa7" "\xa8" "\xa9" [171] "\xaa" "\xab" "\xac" "\xad" "\xae" "\xaf" "\xb0" "\xb1" "\xb2" "\xb3" [181] "\xb4" "\xb5" "\xb6" "\xb7" "\xb8" "\xb9" "\xba" "\xbb" "\xbc" "\xbd" [191] "\xbe" "\xbf" "\xc0" "\xc1" "\xc2" "\xc3" "\xc4" "\xc5" "\xc6" "\xc7" [201] "\xc8" "\xc9" "\xca" "\xcb" "\xcc" "\xcd" "\xce" "\xcf" "\xd0" "\xd1" [211] "\xd2" "\xd3" "\xd4" "\xd5" "\xd6" "\xd7" "\xd8" "\xd9" "\xda" "\xdb" [221] "\xdc" "\xdd" "\xde" "\xdf" "\xe0" "\xe1" "\xe2" "\xe3" "\xe4" "\xe5" [231] "\xe6" "\xe7" "\xe8" "\xe9" "\xea" "\xeb" "\xec" "\xed" "\xee" "\xef" [241] "\xf0" "\xf1" "\xf2" "\xf3" "\xf4" "\xf5" "\xf6" "\xf7" "\xf8" "\xf9" [251] "\xfa" "\xfb" "\xfc" "\xfd" "\xfe" "\xff" > > idxs <- 1:255 > str(idxs) int [1:255] 1 2 3 4 5 6 7 8 9 10 ... > > chars <- intToChar(idxs) > print(chars) [1] "\001" "\002" "\003" "\004" "\005" "\006" "\a" "\b" "\t" "\n" [11] "\v" "\f" "\r" "\016" "\017" "\020" "\021" "\022" "\023" "\024" [21] "\025" "\026" "\027" "\030" "\031" "\032" "\033" "\034" "\035" "\036" [31] "\037" " " "!" "\"" "#" "$" "%" "&" "'" "(" [41] ")" "*" "+" "," "-" "." "/" "0" "1" "2" [51] "3" "4" "5" "6" "7" "8" "9" ":" ";" "<" [61] "=" ">" "?" "@" "A" "B" "C" "D" "E" "F" [71] "G" "H" "I" "J" "K" "L" "M" "N" "O" "P" [81] "Q" "R" "S" "T" "U" "V" "W" "X" "Y" "Z" [91] "[" "\\" "]" "^" "_" "`" "a" "b" "c" "d" [101] "e" "f" "g" "h" "i" "j" "k" "l" "m" "n" [111] "o" "p" "q" "r" "s" "t" "u" "v" "w" "x" [121] "y" "z" "{" "|" "}" "~" "\177" "\x80" "\x81" "\x82" [131] "\x83" "\x84" "\x85" "\x86" "\x87" "\x88" "\x89" "\x8a" "\x8b" "\x8c" [141] "\x8d" "\x8e" "\x8f" "\x90" "\x91" "\x92" "\x93" "\x94" "\x95" "\x96" [151] "\x97" "\x98" "\x99" "\x9a" "\x9b" "\x9c" "\x9d" "\x9e" "\x9f" "\xa0" [161] "\xa1" "\xa2" "\xa3" "\xa4" "\xa5" "\xa6" "\xa7" "\xa8" "\xa9" "\xaa" [171] "\xab" "\xac" "\xad" "\xae" "\xaf" "\xb0" "\xb1" "\xb2" "\xb3" "\xb4" [181] "\xb5" "\xb6" "\xb7" "\xb8" "\xb9" "\xba" "\xbb" "\xbc" "\xbd" "\xbe" [191] "\xbf" "\xc0" "\xc1" "\xc2" "\xc3" "\xc4" "\xc5" "\xc6" "\xc7" "\xc8" [201] "\xc9" "\xca" "\xcb" "\xcc" "\xcd" "\xce" "\xcf" "\xd0" "\xd1" "\xd2" [211] "\xd3" "\xd4" "\xd5" "\xd6" "\xd7" "\xd8" "\xd9" "\xda" "\xdb" "\xdc" [221] "\xdd" "\xde" "\xdf" "\xe0" "\xe1" "\xe2" "\xe3" "\xe4" "\xe5" "\xe6" [231] "\xe7" "\xe8" "\xe9" "\xea" "\xeb" "\xec" "\xed" "\xee" "\xef" "\xf0" [241] "\xf1" "\xf2" "\xf3" "\xf4" "\xf5" "\xf6" "\xf7" "\xf8" "\xf9" "\xfa" [251] "\xfb" "\xfc" "\xfd" "\xfe" "\xff" > stopifnot(length(chars) == length(idxs)) > > idxs2 <- charToInt(chars) > str(idxs2) int [1:255] 1 2 3 4 5 6 7 8 9 10 ... > stopifnot(length(idxs2) == length(chars)) > > stopifnot(identical(idxs2, idxs)) > > > message("TESTING: ASCII...DONE") TESTING: ASCII...DONE > > proc.time() user system elapsed 0.29 0.04 0.32