
import rust_ext
import numpy as np

a = np.array([1.0, 2.0])
rust_ext.mult(3, a)
print(a)


import rust_ext
import numpy as np

x = np.array([1.0, 2.0])
y = np.array([2.0, 3.0])
result = rust_ext.axpy(3, x, y)
print(result)

Use axpy on sample Python script
Use axpy on sample Python script

  
  import rust_ext
  import numpy as np
  
- a = np.array([1.0, 2.0])
+ x = np.array([1.0, 2.0])
- rust_ext.mult(3, a)
- print(a)
+ y = np.array([2.0, 3.0])
+ result = rust_ext.axpy(3, x, y)
+ print(result)
  
Use axpy on sample Python script
## Code Before:

import rust_ext
import numpy as np

a = np.array([1.0, 2.0])
rust_ext.mult(3, a)
print(a)

## Instruction:
Use axpy on sample Python script
## Code After:

import rust_ext
import numpy as np

x = np.array([1.0, 2.0])
y = np.array([2.0, 3.0])
result = rust_ext.axpy(3, x, y)
print(result)
