Skip to content

Commit

Permalink
Fixed Q31 in Linux (#1414)
Browse files Browse the repository at this point in the history
Answer said that brace expansion requires files to exist.
You can test this in a shell by typing `echo number{1,2}`. Parameters expand to `number1` and `number2` always. Brace expansion creates a list.
Now try with globs and type `echo unreal*file`. If the file doesn't exist, and nullglob is not set, then it will remain the same. If there is at least one file matching the pattern, it will expand to the list of matching pathnames.
  • Loading branch information
D4RIO authored Apr 8, 2021
1 parent b6cc274 commit 78514dd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions linux/linux-assesment.md
Original file line number Diff line number Diff line change
Expand Up @@ -229,8 +229,8 @@ echo \$myNumber | sed -e 's/^[[:digit:]][[:digit:]][[:digit:]]/(&)/g'
#### Q31. What is one major difference between brace expansion and globs?

- [ ] Globs create a list; brace expansion matches pattern.
- [x] Brace expansion requires files to exist; globs do not.
- [ ] Brace expansion creates a list; globs mart the list of pathnames.
- [ ] Brace expansion requires files to exist; globs do not.
- [x] Brace expansion creates a list; globs mart the list of pathnames.
- [ ] Globs get processes first and brace expansion later.

#### Q32. To remove all ACLs from a directory , use setfacl with which options?
Expand Down

0 comments on commit 78514dd

Please sign in to comment.