如何在Python中比较字符串

2026-02-12 12:42:09

1

如何在Python中比较字符串

2、Python可使用cmp()方法来比较两个对象,相等返回 0 ,前大于后,返回 1,小于返回 -1。

如何在Python中比较字符串

猜你喜欢