50+ CSS Problems for Practice

Series: ➊
Level of Difficulty: Easy to Medium

Topics:
➊ CSS Selectors
➋ Background
➌ Border
➍ Margin
➎ Padding
➏ Outline
➐ Text
➑ Position
➒ Overflow
➓ Height/Width
💭 Intention behind this Practice Series

⬘ I believe anyone can strengthen his skills in HTML and CSS only by practicing.

⬗ In CSS, there are so many properties and values. It's impossible to memorize everything.

⬙ By practicing a lot, you can definitely master it.
➊ CSS Selectors

➀ Colour all p elements to green
➁ Colour the element with id "sentence" to yellow
➂ Colour all the elements with class "bluepara" to blue
➃ Write minimal code to colour all p and, section elements to green
➋ Background

➀ Set entire page's background colour to red
➁ Set background image for the entire page
➂ Show the background image repeating horizontally/vertically
➃ Show the background image at the top left corner and not repeated
➄ Show the background image fixed
➌ Border

➀ Show dotted border to a paragraph
➁ Set top border dotted, left border dashed, right border solid and bottom border double.
➂ Set border of 4px, solid and color red to a h1
➃ Set the right border to dashed
➄ Draw a circle of radius 20px
➅ Draw an ellipse of radius 15px, 20px
➆ Draw a ring of radius 50px and width 20px
➍ Margin

➀ Set margin of 20px to a button
➁ Set margin of 10px horizontally and 15px vertically to a paragraph
➂ Set different margin values for each side of a h1 element
➎ Padding

➀ Set top padding of a h1 element to 10px
➁ Set padding of 15px each side to a paragraph
➂ Set padding of 10px horizontally and 15px vertically to a paragraph
➏ Outline

➀ Set a 5px solid outline border for a div element
➁ Set the outline border color to red for a paragraph
➐ Text

➀ Center align the text inside a p element
➁ Justify the text inside a p element
➂ Center align only the last line of text inside a p element
➃ Justify the last line of text inside a p element
➄ Style the text inside a paragraph to all uppercase
➅ Style the text inside a h1 to capitalized
➆ Remove underline from a hyperlink
➇ Strike through a text
➈ Display both overline and underline for a text
➉ Give space of 5px between letters
➀➀ Give space of 0.8 between lines in a paragraph
➀➁ Give space of 10px between words
➀➂ Display a text in a paragraph from right-to-left
➀➃ Indent the first line of a paragraph with 10px
➀➄ Display shadow of 5px (both horizontally and vertically) to a text inside a div
➀➅ Add blur of 7px to the shadow
➑ Position

➀ Position some text on the top left corner of an image
➁ Position some text on the top right corner of an image
➂ Position some text on the bottom left corner of an image
➃ Position some text on the bottom right corner of an image
➄ Position some text on the centre of an image
➅ Display some text fixed at a specific position in a page
➆ Display some sticky text in a page
➒ Overflow

➀ Hide the scroll bar for an overflown paragraph
➁ Display the scroll bar to a paragraph only when it's overflown
➓ Height/Width

➀ Set width of a paragraph to be half of the page.
➁ Set the height to 200px for a div
➂ Set the min width to 100px and max width to 300px for a p element
💭 Feedbacks

⬔ Feedbacks of yours on these problems are much appreciated. Those will help me to come up with better quality contents in future.

⬕ If you have any other suggestions, please share.
End of 🧵

Are you looking for such practice questions? I am going to share many on HTML, CSS, JavaScript and React.js in coming days.

If you don't want to miss those, Follow Me ✅

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with Swapna Kumar Panda 

Swapna Kumar Panda  Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @swapnakpanda

Mar 5
JavaScript Interview Questions

Series: ➌
Level: Beginner
Topics:

➊ Functions - Basics
➋ Function Scope
➌ Function Arguments
➍ Anonymous Functions
➎ Higher Order Function & Callbacks
➏ Closure
➐ IIFE
➑ Arrow Functions
🚥 Disclaimer

⬖ The questions covered here are mostly conceptual.
⬘ I never claim only these type of questions are/should be asked during interviews.
⬗ For interviews, you should have fundamentals strong. And you should be able to provide solutions to practical problems.
Read 17 tweets
Mar 3
5 "Must-Know" Date Input Types in HTML

There are 5 input types which allow user to enter/pick date, time, week, month, year etc.

➊ datetime-local
➋ date
➌ time
➍ week
➎ month
➊ datetime-local

⬒ Use this input type if requirement is to pick both "date" and "time" (independent of any timezone).

⬓ We can use 2 other attributes to define the limit restrictions and step values.

❍ min
❍ max
❍ step <input type="datetime-local" >
Read 9 tweets
Mar 2
👩‍💻 HTML & CSS Topics

Learn these
❍ if you are into Web Development
❍ before starting JavaScript

❀ Back-End Developer

❑ You want to learn JavaScript for Node.js environment, you can directly start.

❒ It's not mandatory to have any prior knowledge of HTML & CSS.
❀ Front-End Developer

✔ You can learn basic JavaScript syntaxes even without knowing HTML & CSS.

✘ But you need to switch to HTML & CSS after a point. Then again switch back to JavaScript.

✔ So, I recommend learn HTML & CSS (basics) first and, then jump to JavaScript.
Read 12 tweets
Mar 1
When someone asks me, "How do you grow to 18K from 18 in just 180 days"

I reply: By following these 18 lessons.

🧵 👇
🚥 Disclaimer

⬒ I am not a Growth Expert. Views expressed here are my personal views.

⬔ I don't remember how many followers I had 180 days back.

⬓ None of my tweets are against anyone, any community or, any race. But if you feel attacked, I am really sorry. 🙏
Lesson ➊

Be unique. Have your own style.
Read 21 tweets
Feb 28
🌆 CSS Grid Layout : Properties & Values

Link to High Resolution image in the next tweet. To render contents in Grid layout effectively, there are var
🏙 High Resolution Image

⬒ If you liked this one, give a ⭐️ to this GitHub repo to support my work.

⬓ Direct Link:

github.com/swapnakpanda/I…
🚥 Disclaimer

I have compiled these information with all sincerity. But in case you find any omissions or, wrong representations, please inform me.
Read 4 tweets
Feb 27
10 Sorting Algorithms

⬒ Have you just started studying Data Structures and Algorithms?

⬓ Are you finding difficulties in understanding the sorting algorithms?

I will introduce you here to 10 different sorting algorithms by explaining each using simple terms.
📋 Table of Contents

➊ Bubble Sort
➋ Selection Sort
➌ Insertion Sort
➍ Merge Sort
➎ Quick Sort
➏ Counting Sort
➐ Radix Sort
➑ Bucket Sort
➒ Heap Sort
➓ Shell Sort
➒➑ Time Complexity
➒➒ Space Complexity
Read 18 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Don't want to be a Premium member but still want to support us?

Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal

Or Donate anonymously using crypto!

Ethereum

0xfe58350B80634f60Fa6Dc149a72b4DFbc17D341E copy

Bitcoin

3ATGMxNzCUFzxpMCHL5sWSt4DVtS8UqXpi copy

Thank you for your support!

Follow Us on Twitter!

:(