erlang lists模块函数使用大全
田螺 发布于 7-23
一,带函数Pred1,all(Pred,List)->boolean()如果List中的每个元素作为Pred函数的参数执行,结果都返回true,那么all函数返回true,否则返回false例子:lists:all(fun(E)->trueend,[1,2,3,4]).结果true2,any(Pred,List)->boolea...
阅读(117) 评论(0)
田螺 发布于 7-23
一,带函数Pred1,all(Pred,List)->boolean()如果List中的每个元素作为Pred函数的参数执行,结果都返回true,那么all函数返回true,否则返回false例子:lists:all(fun(E)->trueend,[1,2,3,4]).结果true2,any(Pred,List)->boolea...
阅读(117) 评论(0)
田螺 发布于 3-29
importrequestsfrombs4importBeautifulSoupfrompprintimportpprintimportredefjoke(page):url='http://xx/?m=vod-index-pg-'+str(page)+'.html'header={'User-Agent':'Mozilla/5.0(Window...
阅读(140) 评论(0)
田螺 发布于 10-13
需要配置参数,选择目标-》右侧属性中的AllowDrop=true其次在右侧的事件中找到:DragDrop,DragEnter分别把下面两句拖进去主要是这两处代码:privatevoidForm1_DragEnter(objectsender,DragEventArgse){if(e.Data.GetDataPresent(DataFormats...
阅读(78) 评论(0)
田螺 发布于 10-10
--序列化--序列化时只需传入obj的值,其它保持nilfunctionserialize(obj,name,newline,depth)localspace=newlineand""or""newline=newlineandtruedepth=depthor0ifdepth>10thenreturn"..."endlocaltmp=st...
阅读(62) 评论(0)
田螺 发布于 10-10
for/r%%iin(*.ans)doren%%i*.out批处理的一行代码便解决问题解决问题。。。。。@echooffsetnum=0For/r.%%iin(*.ans)do(set/anum+=1echo%%icallecho第%%num%%个文件处理成功ren%%i*.out)echo共%num%个文件被处理成功pause>nul程序...
阅读(66) 评论(0)
田螺 发布于 9-27
unity5.x中使用了新的资源打包方法,代替4.x时代的BuildAssetBundle方法。但是新的打包方法生成的资源是没有mainAsset的,即assetBundle.mainAsset返回null。但是老代码里需要访问mainAsset的地方怎么办呢,可以使用如下方法:publicstaticUnityEngine.ObjectgetM...
阅读(68) 评论(0)
田螺 发布于 8-16
usingUnityEngine;usingSystem.Collections;usingSystem.Collections.Generic;usingSystem.IO;usingUnityEditor;usingUnityEditor.Animations;publicclassBuildAnimation:Editor{//生成出的Pr...
阅读(96) 评论(0)
田螺 发布于 8-15
//延时发送抢单请求ajaxT=setTimeout(()=>{$.ajax({url:"{:url('submit_order')}",type:"POST",dataType:"JSON",data:{},success:(res=>{console.log(res)status=trueif(res.code==0){QS_to...
阅读(89) 评论(0)
田螺 发布于 8-15
functionis_mobile($tel){if(preg_match("/^1[345789]{1}\d{9}$/",$tel)){returntrue;}else{returnfalse;}}/**检查图片是不是bases64编码的*/functionis_image_base64($base64){if(preg_match('/^(d...
阅读(88) 评论(0)
田螺 发布于 8-15
//生成随机用户名functionget_username(){$chars1="ABCDEFGHIJKLMNOPQRSTUVWXYZ";$chars2="abcdefghijklmnopqrstuvwxyz0123456789";$username="";for($i=0;$i<mt_rand(2,3);$i++){$username.=...
阅读(98) 评论(0)
热门排行
阅读 (261)
1 易语言中的MYSQL操作之超级列表框使用阅读 (234)
2 JS网站点击刷新获取验证码阅读 (156)
3 asp.net 在CS文件中如何POST表单提交,StringBuilder阅读 (140)
4 python采集影视网站实例,这个站表格布局的太麻烦了。阅读 (126)
5 php图片裁剪,图片资源句柄,填充图形宽,剪切类型