Flashcard Deck · 23 cards · Public

Harvard CS50 Web Programming with Python and JavaScript

Master full-stack web development with this high-yield flashcard deck covering Harvard CS50W's core concepts. Dive into HTML5, CSS3, JavaScript, Python/Django, SQL, and React to build dynamic, data-driven web applications.

Cards in this deck

(23 cards)

Preview terms and definitions before starting your study session.

#1
Term
What are semantic HTML5 elements?
Definition
Semantic HTML5 elements clearly describe their meaning to both the browser and the developer. They improve accessibility, SEO, and code readability by providing structure beyond just presentation, making the purpose of content explicit.
#2
Term
Give examples of common semantic HTML5 elements and their purpose.
Definition
Examples include:
  • <header>: Introduces content, often containing navigation or a logo.
  • <nav>: Contains navigation links.
  • <main>: Represents the dominant content of the <body>.
  • <article>: Self-contained, independent content (e.g., a blog post).
  • <section>: A thematic grouping of content.
  • <aside>: Content indirectly related to the main content (e.g., a sidebar).
  • <footer>: Contains copyright info, contact details, etc.
#3
Term
Explain the purpose of CSS Flexbox.
Definition
CSS Flexbox (Flexible Box Layout) is a one-dimensional layout module designed for arranging items in a container, either in a row or a column. It makes distributing space among items and aligning them much easier and more efficient, especially for dynamic content.
#4
Term
Describe the main difference between flex-direction: row and flex-direction: column.
Definition
  • flex-direction: row: Arranges flex items horizontally, from left to right (default). The main axis runs horizontally.
  • flex-direction: column: Arranges flex items vertically, from top to bottom. The main axis runs vertically.
#5
Term
Explain the purpose of CSS Grid.
Definition
CSS Grid Layout is a two-dimensional layout system for the web. It allows developers to define rows and columns, and then place content into these grid cells, making it ideal for designing complex page layouts with precise control over both horizontal and vertical alignment.
#6
Term
How do grid-template-columns and grid-template-rows work in CSS Grid?
Definition
  • grid-template-columns: Defines the number and width of columns in the grid. E.g., grid-template-columns: 1fr 2fr 1fr; creates three columns with relative widths.
  • grid-template-rows: Defines the number and height of rows in the grid. E.g., grid-template-rows: auto 100px; creates two rows, one auto-sized and one 100px tall.
#7
Term
What is the Document Object Model (DOM) in JavaScript?
Definition
The DOM is a programming interface for web documents. It represents the page structure as a tree of objects, where each node is an object representing an HTML element. JavaScript can interact with this tree to dynamically change the content, structure, and style of a web page.
#8
Term
How do you select an element by its ID using JavaScript?
Definition
You use the document.getElementById() method.
javascript1 line
const myElement = document.getElementById('myUniqueId');
This returns the element object with the specified ID, or null if not found.
Showing 8 of 23 cards in this deck.
Study All Now