Practice Real Company Assessment Patterns • Latest 2025–2026 Mock Tests

Programming Exercises

Create a sticky header that remains at the top when scrolling.

Medium

Problem Statement

Create a sticky header that remains at the top when scrolling.

Sample Output

The header stays visible at the top of the page while the rest of the content scrolls.

Limits

Time: 2s · Memory: 256 MB

Code Editor

Try your code in this preview. Submit marks it done.

<!DOCTYPE html> <html> <head> <style> /* Add CSS here to create a sticky header */ </style> </head> <body> <header>Sticky Header</header> <div><p>Content goes here...</p></div> </body> </html>

Document

To view the HTML changes, please type the code within the editor