Skip to content

Commit 90efd34

Browse files
committed
Fix ploop.1.py example
1 parent 13c4c7e commit 90efd34

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

examples/ploop.1.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
1-
import numba
1+
from numba.openmp import njit
22
from numba.openmp import openmp_context as openmp
3-
from numba.openmp import omp_set_num_threads, omp_get_thread_num, omp_get_num_threads, omp_get_wtime
43
import numpy as np
54

6-
@numba.njit
5+
6+
@njit
77
def simple(n, a, b):
88
with openmp("parallel for"):
99
for i in range(1, n):
10-
b[i] = (a[i] + a[i-1]) / 2.0
10+
b[i] = (a[i] + a[i - 1]) / 2.0
11+
1112

1213
a = np.ones(100)
1314
b = np.empty(len(a))

0 commit comments

Comments
 (0)