Bash Code
1 |
echo "hello world." |
C code
1 2 3 4 5 6 |
#include <stdio.h> ; int main(int argc, char *argv[]) { printf("hello, world.\n"); return 0 } |
Python code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
''' Created on 2011-5-5 @author: Jay Ren ''' def dict_test(): a_dict = {'server':'Apache','db':'MySQL'} print(a_dict['db']) a_dict['os'] = 'Linux' print(a_dict) a_dict['db'] = 'Oracle' print(a_dict['db']) b_dict = {1:['Jay','Yongjie'], 2:['Afra','Xuejiao']} print(len(b_dict)) print(b_dict[2][1]) if __name__ == '__main__': dict_test() |