Avatar ·

What is the analog of var_dump() function in Python for debugging variables?

Hello everyone! I'm just starting to learn Python after several years of working with PHP. In PHP, I constantly used the var_dump() function for debugging — it shows the data type, value, and structure of a variable, including arrays and objects. This is very convenient when you need to quickly understand what is stored in a variable. For example, in PHP I write like this: ```php 'Alice', 'age' => 30, 'hobbies' => ['reading', 'swimming']]; var_dump($data); ?> ``` And I get a clear output: ``` array(3) { ["name"]=> string(5) "Alice" ["age"]=> int(30) ["hobbies"]=> array(2) { [0]=> string(7) "reading" [1]=> string(8) "swimming" } } ``` In Python, I tried using print(), but it just outputs the value without the data type and structure. I tried to find something similar, but