-
cheng
-
经常在用apache和tomcat等这些服务器,可是总感觉还是不清楚他们之间有什么关系,在用tomcat的时候总出现apache,总感到迷惑,到底谁是主谁是次,因此特意在网上查询了一些这方面的资料,总结了一下: 一:apache支持静态页,tomcat支持动态的,比如servlet等 一般使用apache+tomcat的话,apache只是作为一个转发,对jsp的处理是由tomcat来处理的。ap
-
python
-
算术运算符+ - * / (加减乘除) %(取模即取余) ** 幂运算:2**3=2的3次方=8 // 取整运算,取商的整数部分 比较运算符== 等于 !=不等于 >大于 < 小于 <= 小于等于 >= 大于等于 赋值运算符赋值包括:链式赋值和交叉式赋值 a=b=1(链式赋值) a,b=b,a (交叉赋值) 逻辑运算符与或非(and or not )# 一:not、an
-
python
-
python函数必懂知识点len(string)返回字符串长度lstrip()去掉左边的空格rstript()去掉字符串末尾的空格encode(usf-8) 默认为UTF-8
-
python
-
import randomoffices =[[],[],[]]
names = ["a","b","c","d","e","f","g","d"]
for name in names:
a = random.randint(0,2)
offices[a].append(name)
i = 1
for office in offices:
print("分配个
-
xiaozhu
-
ubuntu(22.04)启动时,会按次序执行配置文件,如下:/etc/profile全局用户,应用于所有的Shell。~/.profile当前用户,应用于所有的Shell。/etc/bash_bashrc全局用户,应用于Bash Shell。~/.bashrc局部当前,应用于Bash Selllinux启动后环境变量加载的顺序为:etc/profile → /etc/profile.d/*.sh
-
python
-
python列表的使用,for与while的遍历a = ["xiaohuang","xiaoliu","xiaowang"]
for i in a:
print(i)
length = len(a)
o =0
while o
print(a[o])
o +=1
-
python
-
python数据的删除 (del,pop,remove)name = ["A","B","C"]
del name[1] #删除指定下标的对象
name.pop() #删除数组组后的一位
name.remove("B") #删除指定的对象,但是执行一次后失效
print(name)