tailieunhanh - Professional Information Technology-Programming Book part 97
Tham khảo tài liệu 'professional information technology-programming book part 97', công nghệ thông tin, kỹ thuật lập trình phục vụ nhu cầu học tập, nghiên cứu và làm việc hiệu quả | sal. xls ns a 0123456789 .xls sam. xls In this example the pattern has been modified so that the first character would have to be either n or s the second character would have to be a and the third could be any digit specified as 0123456789 . Notice that file was not matched because m did not match the list of allowed characters the 10 digits . When working with regular expressions you will find that you frequently specify ranges of characters 0 through 9 A through Z and so on . To simplify working with character ranges regex provides a special metacharacter - hyphen is used to specify a range. Following is the same example this time using a range ns a 0-9 .xls Pattern 0-9 is functionally equivalent to 0123456789 and so the results are identical to those in the previous example. Ranges are not limited to digits. The following are all valid ranges A-Z matches all uppercase characters from A to Z. a-z matches all lowercase characters from a to z. A-F matches only uppercase characters A to F. A-z matches all characters between ASCII A to ASCII z you should probably never use this pattern because it also includes characters such as and A which fall between Z and a in the ASCII table
đang nạp các trang xem trước