码迷,mamicode.com
首页 >  
搜索关键字:print    ( 43532个结果
Python判断字符串是否符合某一正则表达式
直接上代码:#encode:u8import res1 = 'adkkdk'#判断s1字符串是否负责都为小写的正则an = re.search('^[a-z]+$', s1)if an: print 'yes'else: print 'no'
分类:编程语言   时间:2015-09-24 12:44:02    阅读次数:189
Python数组遍历
直接上代码:colours = ["red","green","blue"]for colour in colours: print colour# red# green# blue第二种方法colours = ["red","green","blue"]for i in range(0, l...
分类:编程语言   时间:2015-09-24 12:37:33    阅读次数:239
Xcode多版本切换
查看当前默认XCode路径 xcode-select?--print-path 切换默认XCode路径 sudo?xcode-select?-switch?需要切换的XCode.app的路径
分类:其他好文   时间:2015-09-24 11:16:13    阅读次数:208
python 行转列
#encoding=utf-8 print '中国' #二维阵列变换 行转化成列,列转化成行 lista=[[1,2,3],[4,5,6],[7,8,9],[10,11,12]] #使用列表推导 listb=[[r[col] for r in lista] for col in...
分类:编程语言   时间:2015-09-24 10:52:08    阅读次数:402
BFS visit tree
There are two ways to conduct BFS on tree.Solution 1 -- Given levelUse recursion to find given level, and print./*Function to print level order traver...
分类:其他好文   时间:2015-09-24 07:06:24    阅读次数:221
php
<?php $temp?=array(); $temp[1]="qq"; //此处声明一个数组 echo?$temp; print?($temp); print_r($temp); var_dump($temp); //echo?此处只能输出变量的值,如果遇到数组只会输出类型 //print()是一个函数.也...
分类:Web程序   时间:2015-09-23 21:19:32    阅读次数:169
c# 了解委托
public delegate void aHandler(string text); public class A1 { public void Print(string txt) { Console.WriteLine(txt + "...
分类:Windows程序   时间:2015-09-23 21:01:42    阅读次数:193
Python学习笔记
1.定义函数并使用示例:1 def shuchu(a,b):#定义函数2 if a>b:3 print(a,'is bigest')4 else:5 print(b,'is bigest')6 shuchu(1,3)#直接调用7 x=78 y=99 s...
分类:编程语言   时间:2015-09-23 19:23:40    阅读次数:155
linux中grep命令-From cyber
1.作用Linux系统中grep命令是一种强大的文本搜索工具,它能使用正则表达式搜索文本,并把匹 配的行打印出来。grep全称是Global Regular Expression Print,表示全局正则表达式版本,它的使用权限是所有用户。2.格式grep [options]3.主要参数[optio...
分类:系统相关   时间:2015-09-23 19:02:40    阅读次数:231
find 命令大全
Linux中find常见用法示例·find path -option [ -print ] [ -exec -ok command ] {} \;find命令的参数;pathname: find命令所查找的目录路径。例如用.来表示当前目录,用/来表示系统根目录。-print: find命令将匹配的文...
分类:其他好文   时间:2015-09-23 18:35:06    阅读次数:262
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!