lixiang


  • Home

  • About

  • Tags

  • Categories

  • Archives

if-else in Python

Posted on 2019-04-24 | Visitors:
求两个数的较大值123456789101112131415# 1.常规if a > b: c = aelse: c = b# 2.表达式c = a if a > b else ...
Read more »

Use Homebrew to Install both Python 2 and 3 on Mac

Posted on 2019-02-02 | Visitors:
起因公司项目使用Python2.7,自己LeetCode刷题想使用Python3 背景macOS中自带了Python2.7,只需要安装Python3 安装Python3一定要用 brew 安装 Pyt ...
Read more »

Method Chaining or Cascading in Python

Posted on 2019-01-23 | Visitors:
12345678910111213141516class Person: def name(self, name): self.name = name return ...
Read more »

Failed to Start Mysql8.0 in Centos7(vultr)

Posted on 2019-01-20 | Visitors:
启动失败 查看日志原因:内存不足Solution 成功开启MySQL获取临时密码1234grep "A temporary password" /var/log/mysqld.log # 修改roo ...
Read more »

Compare Software Version

Posted on 2019-01-13 | In oj | Visitors:
比较任意两个软件版本号大小请用您熟悉的编程语言,编程实现一个比较任意两个软件版本号大小的函数,如 1.2.3a 和 1.2.4b比较,后者版本号更大,请考虑各种情况,不可以使用系统提供的比较函数。 ...
Read more »

Hello World

Posted on 2019-01-13 | In others | Visitors:
Welcome to Hexo! This is your very first post. Check documentation for more info. If you get any pro ...
Read more »

Generate Verification Code in Python

Posted on 2018-12-16 | Visitors:
1234567891011121314151617181920import randomdef generate_verification_code(length=6): """随机生成6位的验 ...
Read more »

List Files and Directory Tree Structure in Python

Posted on 2018-12-16 | Visitors:
123456789101112131415161718192021222324252627282930313233343536import osdef walk(path): l = [] ...
Read more »

Floyd

Posted on 2018-12-15 | Visitors:
问题描述求无向图中各点之间的最短路径长度和对应的最短路径。如果有多条最短路径,给出一条即可。 12345678910111213141516171819202122232425262728293031 ...
Read more »

Sports Meeting

Posted on 2018-12-15 | Visitors:
问题描述学校举行了一个运动会,有以下六个项目。有五位同学报名了相应的项目。假设每个项目所用时间均为一个小时。如何安排各个项目的顺序,使运动会在最短时间内结束。同学的参加的项目顺序可以调换,必须参加自己 ...
Read more »
123…5
li xiang

li xiang

43 posts
6 categories
5 tags
GitHub Twitter Telegram
© 2022 li xiang  京ICP备18019569号
Powered by Hexo
|
Theme — NexT.Mist v5.1.4