Linux Shell命令能力倾向问题和解答

This section contains Aptitude Questions and Answers on Linux Shell Commands.

本节包含有关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?
  1. cmdtype

  2. type

  3. ctype

  4. commandtype

Answer & Explanation

Correct answer: 2
type

The type command is used to check a Linux command is a built-in shell command or external command.

1)以下哪个命令用于检查Linux命令是内置的shell命令还是外部命令?
  1. 命令类型

  2. 类型

  3. 类型

  4. 命令类型

答案与解释

正确答案:2
类型

type命令用于检查Linux命令是内置的shell命令还是外部命令。

2) Which of the following commands are built-in shell commands in the Linux operating system?
  1. pwd

  2. cd

  3. export

  4. echo

Options:

  1. A and B

  2. C and D

  3. A, B, and C

  4. A, B, C, and D

Answer & Explanation

Correct answer: 4
A, B, C, and D

All given commands are built-in shell commands.

2)以下哪些命令是Linux操作系统中的内置shell命令?
  1. 密码

  2. 光盘

  3. 出口

  4. 回声

选项:

  1. A和B

  2. C和D

  3. A,B和C

  4. A,B,C和D

答案与解释

正确答案:4
A,B,C和D

所有给定的命令都是内置的shell命令。

3) Which of the following commands are external commands in the Linux operating system?
  1. cat

  2. file

  3. help

  4. man

Options:

  1. A and B

  2. C and D

  3. A, B, and D

  4. A, B, C, and D

Answer & Explanation

Correct answer: 3
A, B, and D

The cat, file, and man are external commands used in the Linux operating system.

3)以下哪些命令是Linux操作系统中的外部命令?
  1. 文件

  2. 救命

  3. 男子

选项:

  1. A和B

  2. C和D

  3. A,B和D

  4. A,B,C和D

答案与解释

正确答案:3
A,B和D

cat , file和man是Linux操作系统中使用的外部命令。

4) Which of the following command is used to display the path of a command in the Linux File System?
  1. pcmd

  2. which

  3. pathcmd

  4. None of the above

Answer & Explanation

Correct answer: 2
which

The which command is used to display the path of a command in the Linux File System.

4)以下哪个命令用于显示Linux文件系统中命令的路径?
  1. pcmd

  2. 哪一个

  3. 路径

  4. 以上都不是

答案与解释

正确答案:2
哪一个

which命令用于显示Linux文件系统中命令的路径。

5) Which of the following command is used to assign a new name to the Linux built commands?
  1. newcmd

  2. new

  3. alias

  4. aliasname

Answer & Explanation

Correct answer: 3
alias

The alias command is used to assign a new name to the Linux built commands?

5)以下哪个命令用于为Linux内置命令分配新名称?
  1. 新命令

  2. 别名

  3. 别名

答案与解释

正确答案:3
别名

alias命令用于为Linux内置命令分配新名称?

6) Which of the following command is used to enable the shell expansion?
  1. shell +x

  2. shell -x

  3. set -x

  4. set +

Answer & Explanation

Correct answer: 3
set -x

The set –x command is used to enable the shell expansion.

6)以下哪个命令用于启用Shell扩展?
  1. 壳+ x

  2. 壳-x

  3. 设置-x

  4. 设置+

答案与解释

正确答案:3
设置-x

set –x命令用于启用外壳扩展。

7) Which of the following operator is used to execute multiple commands in a single line?
  1. ;

  2. %

  3. &&

  4. ||

Answer & Explanation

Correct answer: 1
;

The semicolon (;) operator is used to executing multiple commands in a single line.

7)以下哪个运算符用于在一行中执行多个命令?
  1. ;

  2. &&

  3. ||

答案与解释

正确答案:1
;

分号(;)运算符用于在一行中执行多个命令。

8) Which of the following command is used to remove an existing alias?
  1. rmalias

  2. unalias

  3. delalias

  4. ralials

Answer & Explanation

Correct answer: 2
unalias

The unalias command is used to remove an existing alias.

8)以下哪个命令用于删除现有别名?
  1. rmalias

  2. 无别名

  3. 德拉利亚斯

  4. 集会

答案与解释

正确答案:2
无别名

unalias命令用于删除现有别名。

9) Which of the following operator is used to comment lines in a shell script file?
  1. //

  2. \\

  3. /**/

  4. #

Answer & Explanation

Correct answer: 4
#

The # operator is used to comment line in a shell script file.

9)以下哪个运算符用于注释Shell脚本文件中的行?
  1. //

  2. \\

  3. / ** /

答案与解释

正确答案:4

#运算符用于注释shell脚本文件中的行。

10) The alias created by "alias" command can be used after exiting from shell?
  1. Yes

  2. No

Answer & Explanation

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”命令创建的别名可以在退出shell后使用吗?
  1. 没有

答案与解释

正确答案:2
没有

不,从shell退出后,可以使用由alias命令创建的别名 。 我们可以通过将别名存储在bash启动文件中来创建永久别名。

11) Which of the following operator is used to store the exit code of a previous command?
  1. $?

  2. %$

  3. ?&

  4. [email protected]

Answer & Explanation

Correct answer: 1
$?

The dollar question mark ($?) is used to store the exit code of a previous command.

11)以下哪个运算符用于存储前一个命令的退出代码?
  1. $?

  2. %$

  3. ?&

  4. [电子邮件保护]

答案与解释

正确答案:1
$?

美元问号( $? )用于存储上一个命令的退出代码。

12) There are the following statements that are given below, which of them are correct about Globbing?
  1. The Globbing is used to recognize the wildcard characters and then expand them into path-name.

  2. The Globbing is also known as path-name expansion.

  3. The File Globbing is not supported by the Linux operating system.

  4. All the above

Options:

  1. A and B

  2. A and C

  3. A, B, and C

  4. D

Answer & Explanation

Correct answer: 1
A and B

Statements A and B are correct about GLobbing in the Linux operating system.

12)下面给出了以下陈述,其中哪些关于Globbing是正确的?
  1. Globbing用于识别通配符,然后将其扩展为路径名。

  2. Globbing也称为路径名扩展。

  3. Linux操作系统不支持File Globbing。

  4. 以上全部

选项:

  1. A和B

  2. A和C

  3. A,B和C

  4. d

答案与解释

正确答案:1
A和B

语句A和B关于Linux操作系统中的GLobbing是正确的。

13) There are the following statements that are given below, which of them are correct about Wildcards in the Linux operating system?
  1. Wildcards are the string patterns that contain some special characters.

  2. Wildcards are used to perform actions on one or more file that uses the same pattern.

  3. Linux shell used wildcard characters for globbing.

  4. All the above

Options:

  1. A and B

  2. A and C

  3. A, B, and C

  4. D

Answer & Explanation

Correct answer: 4
D

All given statements are correct about Wildcards in the Linux operating system.

13)下面给出了以下语句,其中哪些对于Linux操作系统中的通配符是正确的?
  1. 通配符是包含一些特殊字符的字符串模式。

  2. 通配符用于对使用相同模式的一个或多个文件执行操作。

  3. Linux shell使用通配符来进行通配。

  4. 以上全部

选项:

  1. A和B

  2. A和C

  3. A,B和C

  4. d

答案与解释

正确答案:4
d

所有给定的语句对于Linux操作系统中的通配符都是正确的。

14) Which of the following characters are used for wildcards in the Linux operating system?
  1. ?

  2. *

  3. []

  4. <> 

Options:

  1. A and B

  2. A and C

  3. A, B, and C

  4. D

Answer & Explanation

Correct answer: 3
A, B, and C

In the Linux, Question mark ?, asterisk *, and square brackets [] are used as wildcard characters.

14)以下哪些字符在Linux操作系统中用于通配符?
  1. *

  2. []

  3. <>

选项:

  1. A和B

  2. A和C

  3. A,B和C

  4. d

答案与解释

正确答案:3
A,B和C

在Linux中,问号? ,星号*和方括号[]用作通配符。

15) Which of the following command is used to display the last executed commands list?
  1. lastcmd

  2. last

  3. history

  4. chistory

Answer & Explanation

Correct answer: 3
history

The history command is used to display the last executed commands list.

15)以下哪个命令用于显示最后执行的命令列表?
  1. lastcmd

  2. 持续

  3. 历史

  4. 情欲

答案与解释

正确答案:3
历史

历史命令用于显示最后执行的命令列表。

16) Which of the following environment variable is used to specify the number of commands history in the current environment?
  1. $HISTSIZE

  2. $HISSIZE

  3. $HISTORYSIZE

  4. $HSIZE

Answer & Explanation

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)以下哪个环境变量用于指定当前环境中的命令历史记录数?
  1. $ HISTSIZE

  2. $ HISSIZE

  3. $ HISTORYSIZE

  4. $ HSIZE

答案与解释

正确答案:1
$ HISTSIZE

$ HISTSIZE环境变量用于指定当前环境中的命令历史记录数。 也可以根据我们的要求进行修改。

17) Which of the following command is known as "bang bang" in the Linux operating system?
  1. ##

  2. $$

  3. !!

  4. @@

Answer & Explanation

Correct answer: 3
!!

The double exclamation (!!) is known as "bang bang" in the Linux operating system.

17)以下哪个命令在Linux操作系统中被称为“ bang bang”?
  1. ##

  2. $$

  3. !!

  4. @@

答案与解释

正确答案:3
!!

双重感叹号( !! )在Linux操作系统中被称为“ 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?
  1. The "bang bang" command is used to remove commands history.

  2. The "bang bang" command is used to remove execute last executed command.

  3. The "bang bang" command is used to display the last login time of the current user.

  4. None of the above

Answer & Explanation

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)下面给出了以下语句,其中哪些对于Linux操作系统中的“ bang bang”命令是正确的?
  1. “ bang bang”命令用于删除命令历史记录。

  2. “ bang bang”命令用于删除执行最后执行的命令。

  3. “ bang bang”命令用于显示当前用户的最后登录时间。

  4. 以上都不是

答案与解释

正确答案:2
“ bang bang”命令用于删除执行最后执行的命令。

“ bang bang”命令用于删除执行最后执行的命令。

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?
  1. !N

  2. #N

  3. $N

  4. !!N

Answer & Explanation

Correct answer: 1
!N

The single exclamation is used with history numbers to execute the specific command from history.

19)根据命令历史记录中分配的编号,使用哪个命令执行命令,此处用N表示命令历史记录编号?
  1. !N

  2. #N

  3. $ N

  4. !! N

答案与解释

正确答案:1
!N

单个感叹号与历史记录编号一起使用以执行历史记录中的特定命令。

20) Can we embed the new shell on the command line?
  1. Yes

  2. No

Answer & Explanation

Correct answer: 1
Yes

Yes, we can embed the new shell on the command line.

20)我们可以在命令行中嵌入新的shell吗?
  1. 没有

答案与解释

正确答案:1

是的,我们可以在命令行中嵌入新的shell。

翻译自: https://www.includehelp.com/linux/shell-commands-aptitude-questions-and-answers.aspx

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/news/541970.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

php mysql 权重_PHP对MySql的常用操作

关于PHP对MySql的常用操作最近做网站&#xff0c;用PHP操作数据库也很多次了&#xff0c;但总是忘记&#xff0c;参考了网上的很多资料&#xff0c;算是整理记录下。数据库操作类实现数据库的连接&#xff0c;断开&#xff0c;以及请求&#xff1a;/*** Created by PhpStorm.* …

Python timedelta total_seconds()方法与示例

Python timedelta.total_seconds()方法 (Python timedelta.total_seconds() Method) timedelta.timedeltotal_seconds() method is used in the timedelta class of module datetime. timedelta.timedeltotal_seconds()方法在模块datetime的timedelta类中使用。 It uses an i…

static和extern对函数的作用

2019独角兽企业重金招聘Python工程师标准>>> 外部函数&#xff1a;定义的函数能被本文件和其他文件访问 默认情况下所有函数都是外部函数 不允许有同名的外部函数内部函数&#xff1a;定义的函数只能被本文件访问&#xff0c;其他文件不能访问 允许不同文件中有同名…

MySQL从服务器写入报错吗_MySQL主从复制读写分离及奇怪的问题

一直都没有写blog的习惯&#xff0c;以前总觉得自己的脑子就是最好的记忆容器&#xff0c;现在觉得我好像有个假脑子。当时是使用阿里云镜像&#xff0c;安装了两台ECS&#xff0c;结果配置MySQL的时候出现了UUID重复问题。先从配置主从开始吧&#xff0c;值得记录。文中很多部…

python二分法查找程序_查找Python程序的输出| 套装2(基础)

python二分法查找程序Program 1: 程序1&#xff1a; a 10b 3res a/b print "a/b: ", res res float(a/b)print "float (a/b) : ", res res float (a) /float (b)print "float (a/b) : ", res res a/b print "a/b: ", resOutput…

数据库 数据库SQL语句一

字符和日期 --字符和日期都要包含在单引号中 --字符大小写敏感&#xff0c;日期格式敏感 --默认的日期格式是DD-MON-RR--查询当前系统时间 SQL> select sysdate from dual; --查询工资在1000~2000之间的员工信息 SQL> select * from emp where sal>1000 and sal<20…

mysql text保存图片_用mysql 如果包含有文字和图片,那么我要用哪种数据类型存储呢?还是分开,用TEXT和BLOB吗?...

rootytt:/var/lib/mysql-files# for i in seq 1 100; do cp 微信图片_20190711095019.jpg "$i".jpg;done;rootytt:/var/lib/mysql-files# ls100.jpg 17.jpg 25.jpg 33.jpg 41.jpg 4.jpg 58.jpg 66.jpg 74.jpg 82.jpg 90.jpg 99.jpg f8.tsv10.jpg 18…

flask mysql 版本_flask 数据库字段类型

使用flask_sqlalchemy首先引用一下廖雪峰Python教程里关于sqlalchemy的话&#xff0c;这里我们要讲的是flask_sqlalchemy的用法。1. 安装用pip安装即可&#xff0c; 进入cmd控制台输入pip install Flask-SQLAlchemy2. 引用引用方法有2种&#xff0c;旧的和新的。from f...文章邻…

Kafka的配置文件详细描述

在kafka/config/目录下面有3个配置文件&#xff1a; producer.propertiesconsumer.propertiesserver.properties (1).producer.properties:生产端的配置文件 #指定kafka节点列表&#xff0c;用于获取metadata&#xff0c;不必全部指定 #需要kafka的服务器地址&#xff0c;来获取…

Java StreamTokenizer nextToken()方法与示例

StreamTokenizer类nextToken()方法 (StreamTokenizer Class nextToken() method) nextToken() method is available in java.io package. nextToken()方法在java.io包中可用。 nextToken() method is used to parse the next token from the input stream of this StreamTokeni…

二维数组m的元素是4个字符组成的串_串、数组和广义表

1. 串1.1 串的定义ADT String{ 数据对象&#xff1a;D{ai|ai∈CharacterSet, i1, 2, …, n, n≧0} 数据关系&#xff1a;R1{|ai-1, ai∈D, i2, …, n} 基本操作&#xff1a; 生成一个值等于chars的串 复制一个串 判断串是否空串 比较串的大小 返回串元素的个数 将串清空 …

流媒体测试笔记记录之————阿里云监控、OBS、FFmpeg拉流和推流变化比较记录...

OBS设置视频&#xff08;512kbps&#xff09;和音频&#xff08;128kbps&#xff09;比特率 阿里云监控结果&#xff1a; 使用FFmpeg拉流到Nginx 服务器测试比特率 第二次测试&#xff0c;修改视频和音频比特率 OBS设置 阿里云监控 Nginx 比特率变化 FFMPEG 拉流截图

Java RandomAccessFile readChar()方法及示例

RandomAccessFile类readChar()方法 (RandomAccessFile Class readChar() method) readChar() method is available in java.io package. readChar()方法在java.io包中可用。 readChar() method is used to read a character value from this file and it can read character up…

python方差分析模型的预测结果怎么看_statsmodels中方差分析表结果解析

引言通常我们在对多个变量进行统计分析的时候&#xff0c;结果的汇总和整理需要耗费大量的时间和精力&#xff0c;稍有不慎还有可能出现错误。因此在对多个变量统计分析的时候&#xff0c;使用自动化的脚本对结果进行整理和汇总就十分的方便了。这里笔者使用Python当中的statsm…

Java PipedOutputStream connect()方法与示例

PipedOutputStream类的connect()方法 (PipedOutputStream Class connect() method) connect() method is available in java.io package. connect()方法在java.io包中可用。 connect() method is used to cause this PipedOutputStream to be connected to the given PipedInpu…

[转载] 中国象棋软件-引擎实现(一)概述

2005年6月我系第二批科技小组的项目正式确定为实现一款中国象棋对弈软件。基本功能包括人机对战、网络对战。我负责开发人机对战的引擎部分&#xff0c;也就是让计算机下棋。经过了暑假整整两个月的学习与实践&#xff0c;我终于初步完成了程序&#xff0c;虽然电脑的下棋水平实…

Java FilePermission getActions()方法与示例

FilePermission类的getActions()方法 (FilePermission Class getActions() method) getActions() method is available in java.io package. getActions()方法在java.io包中可用。 getActions() method is used to check whether this FilePermission and the given object are…

字符与编码(编码转换)

作为一名程序员&#xff0c;肯定有被乱码困扰的时候&#xff0c;真到了百思不得其解的时候&#xff0c;就会觉得&#xff1a;英文程序员真幸福。但其实只要明白编码之间的转换规律&#xff0c;其实乱码还是很好解决的。我们都知道字符串在保存和传输的时候需要先经过编码成二进…

mysql 刷新二进制日志_使用binlog日志恢复MySQL数据库删除数据的方法

binlog日志简介:binlog 就是binarylog&#xff0c;二进制日志文件&#xff0c;这个文件记录了MySQL所有的DDL和DML(除了数据查询语句)语句&#xff0c;以事件形式记录&#xff0c;还包含语句所执行的消耗的时间。binlog日志包括两类文件&#xff1a;1)二进制日志索引文件(文件名…

Java FileInputStream available()方法与示例

FileInputStream类的available()方法 (FileInputStream Class available() method) available() method is available in java.io package. available()方法在java.io包中可用。 available() method is used to return the number of bytes left that can be read from this Fi…