Observe the following code and identify what will be the output when we run following code | Pandas Question 3

11. Observe the following code and identify what will be the output when we run following code -

Import pandas as pd
Import numpy as np  

df = pd.DataFrame(np.array([[4,6,9],[5,1,3]]))

print(df.shape)
  1. SyntaxError: invalid syntax
  2. KeyError
  3. IndexError
  4. None of the mentioned above

Answer: A) SyntaxError: invalid syntax

Explanation:

When we run the code, invalid syntax error will be reflected.

Comments and Discussions!

Load comments ↻






Copyright © 2024 www.includehelp.com. All rights reserved.