dde272c4b8
i18n - Build Validation / Validate i18n Builds (24) (push) Has been cancelled
CI - Node.js / Lint (24) (push) Has been cancelled
CI - Node.js / Build (24) (push) Has been cancelled
CI - Node.js / Test (24) (push) Has been cancelled
CI - Node.js / Test - Upcoming Changes (24) (push) Has been cancelled
CI - Node.js / Test - i18n (italian, 24) (push) Has been cancelled
CI - Node.js / Test - i18n (portuguese, 24) (push) Has been cancelled
CD - Docker - GHCR Images / Build and Push Images (push) Has been cancelled
35 lines
678 B
Markdown
35 lines
678 B
Markdown
---
|
|
id: 5ea9997bbec2e9bc47e94db4
|
|
title: Developing a Port Scanner
|
|
challengeType: 11
|
|
videoId: z_qkqZS7KZ4
|
|
bilibiliIds:
|
|
aid: 208077317
|
|
bvid: BV1Uh411p7HS
|
|
cid: 409036706
|
|
dashedName: developing-a-port-scanner
|
|
---
|
|
|
|
# --questions--
|
|
|
|
## --text--
|
|
|
|
What is the main difference between the `.connect()` and `.connect_ex()` methods?
|
|
|
|
## --answers--
|
|
|
|
There is no difference between the two methods.
|
|
|
|
---
|
|
|
|
If there is an error or if no host is found, `.connect()` returns an error code while `.connect_ex()` raises an exception.
|
|
|
|
---
|
|
|
|
If there is an error or if no host is found, `.connect()` raises an exception while `.connect_ex()` returns an error code.
|
|
|
|
## --video-solution--
|
|
|
|
3
|
|
|