The keyboard on the Apple computer does not respond when it boots up and shuts down.
Computer turns on then after a few seconds turns off. Is unresponsive to keyboard.
[Re-Titled by Moderator]
Computer turns on then after a few seconds turns off. Is unresponsive to keyboard.
[Re-Titled by Moderator]
Have you tried using another keyboard?
FYI, there are no special startup key sequences available for an Apple Silicon M-series Mac. You must initiate boot to the Options Recovery screen by holding down the power button until it launches the Option boot & recovery screen.
Only Intel Macs have special startup keys to alter booting or trigger special events.
FYI, you should always provide the exact model of the Mac and version of macOS when requesting assistance online since there are so many different models that may have different behaviors & options. You can get this information by clicking the Apple menu and selecting "About This Mac" or by entering the system serial number on the check coverage page here:
Check Your Service and Support Coverage - Apple Support
If you cannot invoke a ROM-resident feature such as Option to invoke Startup Manager or Command-R to invoke Recovery, your Mac needs service.
The keyboard on the Apple computer does not respond when it boots up and shuts down.