bash 下 hash array的支持
来源:互联网 发布:java deletecharat 编辑:程序博客网 时间:2024/04/28 10:23
declare -A region_URLs
region_URLs[beijing]="https://1.com"
region_URLs[shanghai]="https://2.com"
region_URLs[Sydney]="https://3.com"
for site in "${!region_URLs[@]}"; do
echo $site -- ${region_URLs[$site]}
done
root@219:~# bash test.sh
shanghai -- https://2.com
Sydney -- https://3.com
beijing -- https://1.com
References: http://www.artificialworlds.net/blog/2012/10/17/bash-associative-array-examples/
0 0
- bash 下 hash array的支持
- nginx学习——从基本hash表到支持通配符的hash表(下)
- bash array
- bash array
- bash array
- Redis支持的数据类型-Hash
- Linux下Bash的变量使用,echo,read,declare,typeset,array,
- Linux下Bash的变量使用,echo,read,declare,typeset,array,
- bash 的组数(array)处理方法
- Array、Linked和Hash的区别
- perl的array和map/hash
- bash下. : () {} [] [[]] (())的解释
- bash下. : () {} [] [[]] (())的解释
- bash下的空格
- bash下. : () {} [] [[]] (())的解释
- bash下. : () {} [] [[]] (())的解释
- bash下. : () {} [] [[]] (())的解释
- bash下. : () {} [] [[]] (())的解释
- 蘑菇街组件化
- 微信公众号经验
- 自学笔记2(接口中的方法)
- 理解new 一个对象的含义
- App出现ANR时一些主要错误类型
- bash 下 hash array的支持
- 模式识别 机器学习 推荐 书目
- linux关机命令详解
- android!蓝牙BLE
- 设计模式 ( 十八 ) 策略模式Strategy(对象行为型)
- How To Install Openfire On CentOS 7
- 负载均衡基础算法
- [ReactNative集成CodePush教程][三] 集成Code Push的案例说明
- Android Service详解(LocalService)