3.0 KiB
		
	
	
	
	
	
	
	
			
		
		
	
	
			3.0 KiB
		
	
	
	
	
	
	
	
id, title, challengeType, videoUrl, localeTitle
| id | title | challengeType | videoUrl | localeTitle | 
|---|---|---|---|---|
| 587d7db8367417b2b2512ba2 | Restrict Possible Usernames | 1 | Ограничить возможные имена пользователей | 
Description
Instructions
userCheck чтобы он соответствовал ограничениям, перечисленным выше. Tests
tests:
  - text: Ваше регулярное выражение должно соответствовать <code>JACK</code>
    testString: 'assert(userCheck.test("JACK"), "Your regex should match <code>JACK</code>");'
  - text: Ваше регулярное выражение не должно совпадать с <code>J</code>
    testString: 'assert(!userCheck.test("J"), "Your regex should not match <code>J</code>");'
  - text: ''
    testString: 'assert(userCheck.test("Oceans11"), "Your regex should match <code>Oceans11</code>");'
  - text: Ваше регулярное выражение должно соответствовать <code>RegexGuru</code>
    testString: 'assert(userCheck.test("RegexGuru"), "Your regex should match <code>RegexGuru</code>");'
  - text: ''
    testString: 'assert(!userCheck.test("007"), "Your regex should not match <code>007</code>");'
  - text: Ваше регулярное выражение не должно совпадать <code>9</code>
    testString: 'assert(!userCheck.test("9"), "Your regex should not match <code>9</code>");'
Challenge Seed
let username = "JackOfAllTrades";
let userCheck = /change/; // Change this line
let result = userCheck.test(username);
Solution
// solution required