Sure! Here's an example of a simple game written in a single HTML file using JavaScript and enclosed in script tags. It's a 2D game where you control a character trying to avoid zombies. The game will display a timer showing how long you've survived, and when you die, it will show "Game Over" on the screen.
To play the game, you can copy and paste the above code into a blank HTML file and save it. Then, open the file in a web browser on your smartphone. The game will start automatically, and you can use the arrow keys or the on-screen controls of your smartphone to move the character (up, down, left, right) and try to avoid the zombies. The game will show a timer indicating how long you've survived, and when you collide with a zombie, it will display "Game Over" on the screen.