Quiz: What is the purpose of Matrix Builds in CI pipelines?
… code across combinations of runtime versions (e.g. Python 3.9, 3.10, 3.11 on Ubuntu and macOS).
Find tutorials, system documentation, dynamic pages, and interactive quizzes in one place.
… code across combinations of runtime versions (e.g. Python 3.9, 3.10, 3.11 on Ubuntu and macOS).
np.linspace(start, stop, num) generates num evenly spaced samples over a specified closed interval.
Two dimensions are compatible for broadcasting if they are equal or if one of them is 1 (evaluated from right to left).
Basic slicing returns a view sharing the original array buffer; fancy/boolean indexing creates a brand new copy .
Passing -1 signals NumPy to dynamically compute that dimension based on the total elements and specified dimensions.
A Series is a 1D labeled array capable of holding any data type; a DataFrame is a 2D tabular structure aligned by index and columns.
.loc[] indexes by index/column labels and includes the stop slice; .iloc[] indexes by 0-based integer positions and excludes the stop slice.
df.fillna() fills NaN values using a specified scalar, dictionary, or imputation strategy (e.g. forward/back fill).