[oracle@june ~]$ cat continue.sh
for i in a b c d e f g
do
if [ "$i" = "c" ]
then
echo xxxxxxxxxxxxxx
echo "跳过的字符为"$i
continue
fi
done
[oracle@june ~]$ sh -x ./continue.sh
+ for i in a b c d e f g
+ '[' a = c ']'
+ for i in a b c d e f g
+ '[' b = c ']'
+ for i in a b c d e f g
+ '[' c = c ']'
+ echo xxxxxxxxxxxxxx
xxxxxxxxxxxxxx
+ echo $'\314\370\271\375\265\304\327\326\267\373\316\252c'
跳过的字符为c
+ continue
+ for i in a b c d e f g
+ '[' d = c ']'
+ for i in a b c d e f g
+ '[' e = c ']'
+ for i in a b c d e f g
+ '[' f = c ']'
+ for i in a b c d e f g
+ '[' g = c ']' continue 跳过当前循环步,回到循环开始

Shell continue循环的更多相关文章

  1. shell脚本-循环选择语句

    shell脚本-循环选择语句 过程式编程语言: 顺序执行 选择执行 循环执行 注:条件中的变量,可以在执行语句中使用,不用在加上"$". if语句 根据命令的退出状态来执行命令 单 ...

  2. Shell 编程 循环语句

    本篇主要写一些shell脚本循环语句的使用. for 循环 指定次数 #!/bin/bash for ((i=1;i<=10;i++)) do echo $i done [root@localh ...

  3. Shell双重循环、图形排列及九九乘法表

    Shell双重循环.图形排列及九九乘法表 目录 Shell双重循环.图形排列及九九乘法表 一.双重循环 1. 双重循环概述 2. 双重循环结构 二.循环特殊操作 1. exit 2. break 3. ...

  4. Linux Shell系列教程之(十二)Shell until循环

    本文是Linux Shell系列教程的第(十二)篇,更多Linux Shell教程请看:Linux Shell系列教程 在上两篇文章Linux Shell系列教程之(十)Shell for循环和Lin ...

  5. shell for循环+case的脚本(监控程序状态)

    分享一个shell for循环+case的脚本(监控程序状态) 分享一个for循环+case的脚本(监控程序状态并执行相关操作) ,供大家学习参考. 复制代码代码如下: #/bin/bash set ...

  6. shell 各种循环判断

    shell支持的循环有 Shell if else Shell case esac Shell for循环 Shell while循环 Shell until循环

  7. shell脚本--循环结构

    shell的循环结构有while和for两种 for循环 #!/bin/bash #文件名:test.sh i=4 for i in 2 4 6 8 10 do echo $i done echo $ ...

  8. Linux Shell系列教程之(十一)Shell while循环

    本文是Linux Shell系列教程的第(十一)篇,更多Linux Shell教程请看:Linux Shell系列教程 在上一篇Linux Shell系列教程之(十)Shell for循环中,我们已经 ...

  9. Linux Shell系列教程之(十)Shell for循环

    本文是Linux Shell系列教程的第(十)篇,更多Linux Shell教程请看:Linux Shell系列教程 基本任何语言都有自己的循环语句,Shell当然也不例外,今天就为大家介绍下Shel ...

随机推荐

  1. hadoop1.X安装

    1.      配置主机的名称 master,slave1,slave2 2.      安装JDK: 3.      配置IP与主机名称的映射: 192.168.0.100 master 192.1 ...

  2. Liferay 6.1开发学习

    http://www.huqiwen.com/2013/01/10/liferay-6-1-development-study-17-springmvc-portlet/ http://www.blo ...

  3. 【解决】hive动态添加partitions不能超过100的问题

    Author: kwu [解决]hive动态添加partitions不能超过100的问题,全量动态生成partitions超过100会出现例如以下异常: The maximum number of d ...

  4. C# DBNULL与NULL之间的区别【转】

    null是.net中无效的对象引用.DBNull是一个类.DBNull.Value是它唯一的实例.它指数据库中数据为空(<NULL>)时,在.net中的值.null表示一个对象的指向无效, ...

  5. 6、第六课,js jquery20150928

    1.声明事件,给事件添加动作 function MyClick() { alert("这是我的第一个js") } 2.js特点 A.js区分大小写 B.弱类型变量,定义一个变量 v ...

  6. 使用DML语句【weber出品必属精品】

    DML语句包含以下语法: INSERT:往一个表中增加新行 DELETE:从一个表中删除掉现有的行 UPDATE:更改一个表中现有的行 INSERT语句语法:INSERT INTO TABLE(COL ...

  7. PHP Filesystem

    Runtime 配置 Filesystem 函数的行为受到 php.ini 中设置的影响. Filesystem 配置选项: 名称 默认 描述 可改变 allow_url_fopen "1& ...

  8. dom方法读取xml(不常用)

    Book.java package com.xml.demo; public class Book { private int id; private String name; private Flo ...

  9. 27 Java动态加载第三方jar包中的类

    我加载的方法是://参数fileName是jar包的路径,processorName 是业务类的包名+类名public static A load(String fileName, String pr ...

  10. vimtutor-summary