Linux Shell命令能力倾向问题和解答
This section contains Aptitude Questions and Answers on Linux Shell Commands.
本節(jié)包含有關(guān)Linux Shell命令的 Aptitude問答。
1) Which of the following command is used to check a Linux command is a built-in shell command or external command?cmdtype
type
ctype
commandtype
Correct answer: 2
type
The type command is used to check a Linux command is a built-in shell command or external command.
1)以下哪個(gè)命令用于檢查Linux命令是內(nèi)置的shell命令還是外部命令?命令類型
類型
類型
命令類型
正確答案:2
類型
type命令用于檢查Linux命令是內(nèi)置的shell命令還是外部命令。
2) Which of the following commands are built-in shell commands in the Linux operating system?pwd
cd
export
echo
Options:
A and B
C and D
A, B, and C
A, B, C, and D
Correct answer: 4
A, B, C, and D
All given commands are built-in shell commands.
2)以下哪些命令是Linux操作系統(tǒng)中的內(nèi)置shell命令?密碼
光盤
出口
回聲
選項(xiàng):
A和B
C和D
A,B和C
A,B,C和D
正確答案:4
A,B,C和D
所有給定的命令都是內(nèi)置的shell命令。
3) Which of the following commands are external commands in the Linux operating system?cat
file
help
man
Options:
A and B
C and D
A, B, and D
A, B, C, and D
Correct answer: 3
A, B, and D
The cat, file, and man are external commands used in the Linux operating system.
3)以下哪些命令是Linux操作系統(tǒng)中的外部命令?貓
文件
救命
男子
選項(xiàng):
A和B
C和D
A,B和D
A,B,C和D
正確答案:3
A,B和D
cat , file和man是Linux操作系統(tǒng)中使用的外部命令。
4) Which of the following command is used to display the path of a command in the Linux File System?pcmd
which
pathcmd
None of the above
Correct answer: 2
which
The which command is used to display the path of a command in the Linux File System.
4)以下哪個(gè)命令用于顯示Linux文件系統(tǒng)中命令的路徑?pcmd
哪一個(gè)
路徑
以上都不是
正確答案:2
哪一個(gè)
which命令用于顯示Linux文件系統(tǒng)中命令的路徑。
5) Which of the following command is used to assign a new name to the Linux built commands?newcmd
new
alias
aliasname
Correct answer: 3
alias
The alias command is used to assign a new name to the Linux built commands?
5)以下哪個(gè)命令用于為Linux內(nèi)置命令分配新名稱?新命令
新
別名
別名
正確答案:3
別名
alias命令用于為Linux內(nèi)置命令分配新名稱?
6) Which of the following command is used to enable the shell expansion?shell +x
shell -x
set -x
set +
Correct answer: 3
set -x
The set –x command is used to enable the shell expansion.
6)以下哪個(gè)命令用于啟用Shell擴(kuò)展?殼+ x
殼-x
設(shè)置-x
設(shè)置+
正確答案:3
設(shè)置-x
set –x命令用于啟用外殼擴(kuò)展。
7) Which of the following operator is used to execute multiple commands in a single line?;
%
&&
||
Correct answer: 1
;
The semicolon (;) operator is used to executing multiple commands in a single line.
7)以下哪個(gè)運(yùn)算符用于在一行中執(zhí)行多個(gè)命令?;
%
&&
||
正確答案:1
;
分號(hào)(;)運(yùn)算符用于在一行中執(zhí)行多個(gè)命令。
8) Which of the following command is used to remove an existing alias?rmalias
unalias
delalias
ralials
Correct answer: 2
unalias
The unalias command is used to remove an existing alias.
8)以下哪個(gè)命令用于刪除現(xiàn)有別名?rmalias
無別名
德拉利亞斯
集會(huì)
正確答案:2
無別名
unalias命令用于刪除現(xiàn)有別名。
9) Which of the following operator is used to comment lines in a shell script file?//
\\
/**/
#
Correct answer: 4
#
The # operator is used to comment line in a shell script file.
9)以下哪個(gè)運(yùn)算符用于注釋Shell腳本文件中的行?//
\\
/ ** /
#
正確答案:4
#
#運(yùn)算符用于注釋shell腳本文件中的行。
10) The alias created by "alias" command can be used after exiting from shell?Yes
No
Correct answer: 2
No
No, the alias created by the alias command can be used after exiting from shell. We can create permanent alias by storing alias in the bash startup file.
10)“ alias”命令創(chuàng)建的別名可以在退出shell后使用嗎?是
沒有
正確答案:2
沒有
不,從shell退出后,可以使用由alias命令創(chuàng)建的別名 。 我們可以通過將別名存儲(chǔ)在bash啟動(dòng)文件中來創(chuàng)建永久別名。
11) Which of the following operator is used to store the exit code of a previous command?$?
%$
?&
[email?protected]
Correct answer: 1
$?
The dollar question mark ($?) is used to store the exit code of a previous command.
11)以下哪個(gè)運(yùn)算符用于存儲(chǔ)前一個(gè)命令的退出代碼?$?
%$
?&
[電子郵件保護(hù)]
正確答案:1
$?
美元問號(hào)( $? )用于存儲(chǔ)上一個(gè)命令的退出代碼。
12) There are the following statements that are given below, which of them are correct about Globbing?The Globbing is used to recognize the wildcard characters and then expand them into path-name.
The Globbing is also known as path-name expansion.
The File Globbing is not supported by the Linux operating system.
All the above
Options:
A and B
A and C
A, B, and C
D
Correct answer: 1
A and B
Statements A and B are correct about GLobbing in the Linux operating system.
12)下面給出了以下陳述,其中哪些關(guān)于Globbing是正確的?Globbing用于識(shí)別通配符,然后將其擴(kuò)展為路徑名。
Globbing也稱為路徑名擴(kuò)展。
Linux操作系統(tǒng)不支持File Globbing。
以上全部
選項(xiàng):
A和B
A和C
A,B和C
d
正確答案:1
A和B
語句A和B關(guān)于Linux操作系統(tǒng)中的GLobbing是正確的。
13) There are the following statements that are given below, which of them are correct about Wildcards in the Linux operating system?Wildcards are the string patterns that contain some special characters.
Wildcards are used to perform actions on one or more file that uses the same pattern.
Linux shell used wildcard characters for globbing.
All the above
Options:
A and B
A and C
A, B, and C
D
Correct answer: 4
D
All given statements are correct about Wildcards in the Linux operating system.
13)下面給出了以下語句,其中哪些對(duì)于Linux操作系統(tǒng)中的通配符是正確的?通配符是包含一些特殊字符的字符串模式。
通配符用于對(duì)使用相同模式的一個(gè)或多個(gè)文件執(zhí)行操作。
Linux shell使用通配符來進(jìn)行通配。
以上全部
選項(xiàng):
A和B
A和C
A,B和C
d
正確答案:4
d
所有給定的語句對(duì)于Linux操作系統(tǒng)中的通配符都是正確的。
14) Which of the following characters are used for wildcards in the Linux operating system??
*
[]
<>?
Options:
A and B
A and C
A, B, and C
D
Correct answer: 3
A, B, and C
In the Linux, Question mark ?, asterisk *, and square brackets [] are used as wildcard characters.
14)以下哪些字符在Linux操作系統(tǒng)中用于通配符??
*
[]
<>
選項(xiàng):
A和B
A和C
A,B和C
d
正確答案:3
A,B和C
在Linux中,問號(hào)? ,星號(hào)*和方括號(hào)[]用作通配符。
15) Which of the following command is used to display the last executed commands list?lastcmd
last
history
chistory
Correct answer: 3
history
The history command is used to display the last executed commands list.
15)以下哪個(gè)命令用于顯示最后執(zhí)行的命令列表?lastcmd
持續(xù)
歷史
情欲
正確答案:3
歷史
歷史命令用于顯示最后執(zhí)行的命令列表。
16) Which of the following environment variable is used to specify the number of commands history in the current environment?$HISTSIZE
$HISSIZE
$HISTORYSIZE
$HSIZE
Correct answer: 1
$HISTSIZE
The $HISTSIZE environment variable is used to specify the number of commands history in the current environment. It can also modify according to our requirements.
16)以下哪個(gè)環(huán)境變量用于指定當(dāng)前環(huán)境中的命令歷史記錄數(shù)?$ HISTSIZE
$ HISSIZE
$ HISTORYSIZE
$ HSIZE
正確答案:1
$ HISTSIZE
$ HISTSIZE環(huán)境變量用于指定當(dāng)前環(huán)境中的命令歷史記錄數(shù)。 也可以根據(jù)我們的要求進(jìn)行修改。
17) Which of the following command is known as "bang bang" in the Linux operating system?##
$$
!!
@@
Correct answer: 3
!!
The double exclamation (!!) is known as "bang bang" in the Linux operating system.
17)以下哪個(gè)命令在Linux操作系統(tǒng)中被稱為“ bang bang”?##
$$
!!
@@
正確答案:3
!!
雙重感嘆號(hào)( !! )在Linux操作系統(tǒng)中被稱為“ bang bang”。
18) There are the following statements that are given below, which of them are correct about "bang bang" command in the Linux operating system?The "bang bang" command is used to remove commands history.
The "bang bang" command is used to remove execute last executed command.
The "bang bang" command is used to display the last login time of the current user.
None of the above
Correct answer: 2
The "bang bang" command is used to remove execute last executed command.
The "bang bang" command is used to remove execute last executed command.
18)下面給出了以下語句,其中哪些對(duì)于Linux操作系統(tǒng)中的“ bang bang”命令是正確的?“ bang bang”命令用于刪除命令歷史記錄。
“ bang bang”命令用于刪除執(zhí)行最后執(zhí)行的命令。
“ bang bang”命令用于顯示當(dāng)前用戶的最后登錄時(shí)間。
以上都不是
正確答案:2
“ bang bang”命令用于刪除執(zhí)行最后執(zhí)行的命令。
“ bang bang”命令用于刪除執(zhí)行最后執(zhí)行的命令。
19) Which command is used to execute a command based on the number assigned in the command history, here we denote command history number by N?!N
#N
$N
!!N
Correct answer: 1
!N
The single exclamation is used with history numbers to execute the specific command from history.
19)根據(jù)命令歷史記錄中分配的編號(hào),使用哪個(gè)命令執(zhí)行命令,此處用N表示命令歷史記錄編號(hào)?!N
#N
$ N
!! N
正確答案:1
!N
單個(gè)感嘆號(hào)與歷史記錄編號(hào)一起使用以執(zhí)行歷史記錄中的特定命令。
20) Can we embed the new shell on the command line?Yes
No
Correct answer: 1
Yes
Yes, we can embed the new shell on the command line.
20)我們可以在命令行中嵌入新的shell嗎?是
沒有
正確答案:1
是
是的,我們可以在命令行中嵌入新的shell。
翻譯自: https://www.includehelp.com/linux/shell-commands-aptitude-questions-and-answers.aspx
總結(jié)
以上是生活随笔為你收集整理的Linux Shell命令能力倾向问题和解答的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 阿姆斯特朗数_阿姆斯特朗的功能依赖公理
- 下一篇: c# 插入树形数据#_C#数据类型能力问