I recently bought Minecraft Java Edition for my laptop and when I first started it up it refused me to play the game, coming up with a "Exit Code: 0" and I have updated everything in my laptop, drivers, java, you name it, as far as I know I have nothing wrong with my laptop with is also brand new by the way. not even 3 months old, so I cannot be told it is laptop issues, I have windows 11 and its frustrating to know that I cannot play, its been happening for so long, I mean when I first bought Minecraft I installed it and it just, shut down, Wouldn't allow me to play, see I went back to 1.16.5 and it worked fine, but its got something to do with the most recent download of minecraft.
Can you attach a crash log?
.minecraft/crash-reports/crash-<date>-client.txt