SQA Tools Blog

Learn testing and automation, one article at a time

Free tutorials, solved practice problems and interview prep for QA and automation engineers: Python, Playwright, Selenium, SQL, Git and more.

1,677Articles
1,141Solved Python problems
7Topics
100%Free

Latest articles

1,677 articles · page 91 of 140
Python practice

Do two arrays have the same shape?

Write a NumPy program to check whether two arrays have the same dimensions. Step-by-step explanation, colour-coded code and real output.

1 min readRead →
Python practice

Create and reshape

Write a NumPy program to create an array and reshape it. Step-by-step explanation, colour-coded code and real output.

1 min readRead →
Python practice

Array to a DataFrame with headers

Write a NumPy program to convert an array into a pandas DataFrame with column headers. Step-by-step explanation, colour-coded code and real output.

1 min readRead →
Python practice

Merge arrays of the same shape

Write a NumPy program to merge two arrays of identical shape. Step-by-step explanation, colour-coded code and real output.

1 min readRead →
Python practice

Row averages ignoring NaN

Write a NumPy program to calculate the average of each row, ignoring NaNs. Step-by-step explanation, colour-coded code and real output.

1 min readRead →
Python practice

Sum of all columns

Write a NumPy program to calculate the sum of each column. Step-by-step explanation, colour-coded code and real output.

1 min readRead →
Python practice

Copy an array

Write a NumPy program to copy data from one array to another. Step-by-step explanation, colour-coded code and real output.

1 min readRead →
Python practice

Top-left 2 × 2 block

Write a NumPy program to extract the first and second elements of the first and second rows. Step-by-step explanation, colour-coded code and real output.

1 min readRead →
Python practice

First two columns

Write a NumPy program to access the first two columns of an array. Step-by-step explanation, colour-coded code and real output.

1 min readRead →
Python practice

Save an array to CSV

Write a NumPy program to save an array to a CSV file. Step-by-step explanation, colour-coded code and real output.

1 min readRead →
Python practice

Product of an array

Write a NumPy program to calculate the product of an array. Step-by-step explanation, colour-coded code and real output.

1 min readRead →
Python practice

Is an array empty?

Write a NumPy program to check whether an array is empty. Step-by-step explanation, colour-coded code and real output.

1 min readRead →

Preparing for a QA interview?

Take free timed mock tests with answers and explanations.