The first command updates the package lists, and the second command upgrades any packages that have new versions available. The -y option automatically confirms any prompts, but you can omit it to ...
Administrator commands now require a password by default.
The Raspberry Pi developers have improved security in Raspberry Pi OS 6.2. They are disabling passwordless sudo.