What do you want to save?
Add Code snippet
New code examples
-
-
Python 2021-11-02 20:39:23
numpy unique vs set
strs = np.repeat(np.array(['a', 'b', 'c'], dtype='O'), 10000) In [11]: %timeit pd.unique(strs) 558 µs ± 16.6 µs per loop (mean ± std. dev. of 7 runs, 1000 loops each) In [12]: %timeit list(set(strs)) 531 µs ± 13.7 ... Add solution -
Python 2021-10-17 06:02:04
python numpy how to empty array cycle
In [210]: %%timeit .....: l = [] .....: for i in xrange(1000): .....: l.append([3*i+1,3*i+2,3*i+3]) .....: l = np.asarray(l) .....: 1000 loops, best of 3: 1.18 ms per loop In [211]: %%timeit .....: a = np.empty((0,3), int) ........ Add solution -
Python 2021-09-22 15:07:02
typing test python
How to test Typing Speed using Python? Difficulty Level : Basic Last Updated : 05 Sep, 2020 Prerequisites: Python GUI – tkinter #We will create a program test the typing speed of the user with a basic GUI application using Python language. Here th... Add solution
Best helpers
+5
+5
+5
+5
+5
+5
+5
+5
+5
+5