摘要: 树莓派 -- mysql 安装linuxmysqlYesterday is a history, tomorrow is a mystery, but today is a gift. 前序mysql 在树莓派 raspberry pi 上的安装和在 Linux 上的差不多,因为网上的教程只是记述了一部分且遇到了情况,就整理下来 安装因为不知道突然执行了什么操作,然后系统执行什么命令都要权限... 阅读全文
posted @ 2017-11-27 23:13 onlypinsily 阅读(5844) 评论(0) 推荐(0) 编辑
摘要: python -- Counter 类我明白你会来,所以我等 参考官方文档 class collections.Counter([iterable-or-mapping])Counter 集成于 dict 类,因此也可以使用字典的方法,此类返回一个以元素为 key 、元素个数为 value 的 Counter 对象集合>>> from collections import Counter>>... 阅读全文
posted @ 2017-11-27 21:00 onlypinsily 阅读(10008) 评论(0) 推荐(0) 编辑
摘要: python -- Counter 类我明白你会来,所以我等 参考官方文档 class collections.Counter([iterable-or-mapping])Counter 集成于 dict 类,因此也可以使用字典的方法,此类返回一个以元素为 key 、元素个数为 value 的 Counter 对象集合>>> from collections import Counter>>... 阅读全文
posted @ 2017-11-27 21:00 onlypinsily 阅读(190) 评论(0) 推荐(0) 编辑
摘要: python -- join()pythonjoinos月似当时,人似当时否? 总在 python 中,一共有两个 join 方法,一个是 str.join(),另一个是 os.path.join() ,这里只了解前一种 str.join(iterable)官方文档Return a string which is the concatenation of the strings in ite... 阅读全文
posted @ 2017-11-27 15:03 onlypinsily 阅读(2018) 评论(0) 推荐(1) 编辑
摘要: python -- enumerate()python enumerateAgain and again,and to the end今天遇到一个新的函数 enumerate(), 可以从一个可迭代对象(dict,list,string 等)同时得到索引和值,这样就避免了另外生成变量来操作了>>> l = ["hello","this","is","my","name"]>>> for inde... 阅读全文
posted @ 2017-11-27 15:01 onlypinsily 阅读(501) 评论(0) 推荐(0) 编辑