Python 3 equivalent of SimpleHTTPServer

0 votes

Can anyone tell the equivalent of python -m SimpleHTTPServer in Python 3?

Nov 20, 2018 in Python by ana1504.k
• 7,870 points
68 views

1 answer to this question.

0 votes
The SimpleHTTPServer module has been merged into http.server in Python 3.0. The 2 to 3 tool will automatically adapt imports when converting your sources to 3.0.

So, your command is python3 -m http.server.
answered Nov 20, 2018 by SDeb
• 13,160 points

Related Questions In Python

0 votes
1 answer

The equivalent of a GOTO in python ​​

Gotos are universally reviled in computer science ...READ MORE

answered Sep 3, 2018 in Python by Priyaj
• 56,520 points
466 views
0 votes
1 answer

What is the equivalent of NotImplementedError using Python?

Hi, good question! One simple answer to your ...READ MORE

answered Jan 17 in Python by Nymeria
• 3,520 points
43 views
0 votes
1 answer
0 votes
1 answer

Create 3*4 array of random numbers - Python

To create different arrays like random arrays:  np.random.rand(3,4) ...READ MORE

answered May 24 in Python by Umer
20 views
+1 vote
2 answers

how can i count the items in a list?

Syntax :            list. count(value) Code: colors = ['red', 'green', ...READ MORE

answered Jul 6 in Python by Neha
• 330 points

edited Jul 8 by Kalgi 226 views
0 votes
1 answer

Equivalent of a?b:c in Python

In Python 2.5, you can use ternary ...READ MORE

answered Jan 7 in Python by SDeb
• 13,160 points
33 views
0 votes
1 answer

How is Python 2.7.3 and Python 3.3 different?

raw_input() is not used in Python 3. Use input()  ...READ MORE

answered Sep 12, 2018 in Python by SDeb
• 13,160 points
34 views