2016-08-07 1 views

답변

2

문자는 급성 악센트이고 유니 코드는 00B4입니다. 우분투에서는 그 사용 Ctrl 키 + 시프트에게 + U를 입력 한 다음 00B4 다음 공간를 입력 할 수 있습니다. 그러나 정규식 리터럴이 둘 이상의 문자 인 경우에는 아포스트로피를 사용할 수 있습니다.

Regular expression literals have type Regex and are written: 

´\b(foo|bar)\b´  -- string enclosed in grave accents 
'\w+'     -- string with length > 1 enclosed in apostrophes 
The notation with the apostrophes has been introduced because many have a hard time entering a grave accent mark on their terminal. However, it is not possible to write a regular expressions with length 1 this way, because then the literal gets interpreted as Char literal. (One can write something like '(?:X)' for a Regex that matches a single 'X'). 
:

doc를 인용