Notes, summaries, assignments, exams, and problems for Baccalaureate

Sort by
Subject
Level

C++ Priority Queue Implementation: Code & Explanation

Classified in Computers

Written on in English with a size of 3.58 KB

C++ Priority Queue Implementation

This document provides a C++ implementation of a priority queue using a heap data structure. The code includes the class definition, member functions, and supporting utilities.

Priority Queue Class Definition


#ifndef priority_queue_h_
#define priority_queue_h_

#include <iostream>
#include <vector>
#include <cassert>

template <class T>
class priority_queue {
private:
    std::vector<T> m_heap;

public:
    priority_queue() {}

    priority_queue(std::vector<T> const& values)
    {
        m_heap = values;
        for (int i = 0; i < m_heap.size(); i++){
            percolate_down(i);
            for (int j = i; j < m_heap.size(); j++){
                percolate_down(
... Continue reading "C++ Priority Queue Implementation: Code & Explanation" »

Fundamental Concepts of Physics: Thermodynamics & Waves

Classified in Physics

Written on in English with a size of 3.22 KB

Fundamental Concepts in Physics

The Atom

An atom is composed of electrons, protons, and neutrons.

Temperature

Temperature is the physical quantity that describes the sensation of cold or hot, directly related to the average kinetic energy of molecules. It represents the average kinetic energy of each molecule.

Heat

Heat is the transfer of energy from one body to another due to a temperature difference. It is a form of energy that can be perceived through temperature variations.

Types of Thermal Expansion

  • Linear Expansion
  • Surface Expansion
  • Volumetric Expansion

Thermodynamics

Thermodynamics is the branch of physics that studies heat transfer and the conversion of energy into its various forms.

Laws of Thermodynamics

  • Zeroth Law
  • First Law
  • Second Law
Zeroth Law
... Continue reading "Fundamental Concepts of Physics: Thermodynamics & Waves" »

Mastering Conditional Sentences, Passive Voice, and Reported Speech in English

Classified in English

Written on in English with a size of 3.55 KB

Conditional Sentences

First Conditional

Structure: If + Present Simple -> Future Simple or may/might + Imperative

Examples:

  • If you are left-handed, you will face many disadvantages.
  • You will meet a lot of people if you travel abroad.
  • If she is free tomorrow, she may/might attend the concert too.

Second Conditional

Structure: If + Past Simple -> would + Base Form or could/might

Examples:

  • If we had enough money, we would buy a new car.
  • You could/might learn more this year if you studied harder.

Third Conditional

Structure: If + Past Perfect -> would have + Past Participle or could/might have

Examples:

  • If I had phoned my parents, they wouldn't have been worried.
  • He could/might have visited her if he had known she was ill.

Passive Voice

Present Simple

  • Active:
... Continue reading "Mastering Conditional Sentences, Passive Voice, and Reported Speech in English" »

Bécquer's Late Romantic Period: Poetry, Prose, and Theater

Classified in Latin

Written on in English with a size of 2.81 KB

Bécquer's Late Romantic Works

Poetry

Rimas

Bécquer's most famous work, Rimas, is a collection of 79 short poems characterized by their intimate tone, simple vocabulary, and assonant rhyme. These poems explore themes of love, inspiration, disillusionment, and loneliness. They are grouped into four series that trace the arc of a love story:

  1. The Mystery of Poetry (1-11)
  2. Hopeful and Joyous Love (12-29)
  3. Love's Disillusionment (30-51)
  4. Loneliness and Emptiness (52-79)

Bécquer's style avoids the loudness and effects of earlier Romantic poetry, favoring a soft rhythm and evocative language.

Characteristics

  • Influence of popular poetry: Short, direct verses with assonance and repetition.
  • Influence of Symbolism: Exploration of interior experiences and the ineffable
... Continue reading "Bécquer's Late Romantic Period: Poetry, Prose, and Theater" »

Essential Demographic Concepts and Spanish Population Data

Classified in Geography

Written on in English with a size of 3.56 KB

Essential Demographic Concepts and Population Statistics

Census of Population Definition

The Census of Population is a count of the population of a country at a specific time. It collects demographic, economic, and social data on the population and housing characteristics. It is a state statistical operation that provides a snapshot of people at a given moment. Its information can only be published in numerical form, without individual references. In Spain, the census is typically conducted every ten years.

Understanding Natural Growth

Natural Growth is the change (increase or decrease) in the number of people in a population during a specified period, resulting from the balance between births and deaths.

Migration and Emigration Dynamics

An Emigrant... Continue reading "Essential Demographic Concepts and Spanish Population Data" »

Dd

Classified in Biology

Written on in English with a size of 1.22 KB

FIRST CONDITIONAL If/unless + present simple, will+infinitive. Possible accio futura
SECOND CONDITIONAL If + past simple, would + infinitive imaginarias o improbables futures o presents accions
THIRD CONDITIONAL If+had past participle, wold have+ past participle. Accions dubtoses en el passat en el pasat.(hagues+hauria)
wish:wish+past sinple=present situation that the speaker is unhappy about.he wishes his friends were here now
wish+past perfect= se arrepiente de una accion pasada.i wish he had called me.
wish+could/would+base form=desire to something to happen in the future.i wish i could go to university

The characters in "The Innocents". Miguel Delibes

Classified in Language

Written on in English with a size of 22.12 KB

CHARACTERS.
The gallery of characters who appear in
LSI denotes the author's strong concern for human beings. Some of the characters acquire highlighted other elements of the
novel: the landscape has value in the relationship that the characters have with him: the universe
depends on the nature theme, ideology and the relationships between the characters, the society presented is conditioned by the lifestyle of each other, and so on. The Holy Innocents is thus a
novel of character: the axis from which depends the whole anatomy, the characters. Quantitatively and qualitatively, the largest proportion of the text reserves the portrayal of human figures.

2.7.1. Classification
The number of characters who move through the farm is considerably... Continue reading "The characters in "The Innocents". Miguel Delibes" »

Domestic Electrical Installations

Classified in Technology

Written on in English with a size of 14.02 KB

ELECTRICAL INSTALLATIONS:
The electricity used to meet our energy needs (housing, buildings and industries) But there are serious dangers such as fires and electrocucions if facilities do not meet the appropriate security.
Low Voltage Electrotechnical Regulations (REBT) technical conditions and guarantees must be met by electrical installations connected to a low voltage supply in order to:
-Preserve the safety of persons and property.
-Ensure the normal operation of these facilities and prevent disruptions that could cause other facilities and prevent disruptions that could cause other facilities and services.
-Contribute to the technical reliability and efficiency of economic facilities.
Complementary technical instructions (ITC - BT)... Continue reading "Domestic Electrical Installations" »

The Great Debate: City Energy vs. Countryside Calm

Classified in English

Written on in English with a size of 5.29 KB

Big Cities or Small Villages?

Nerea (excited): Silvia, imagine us living in a big city — lights, cafés, subways, people everywhere! It’s so alive!

Silvia (smiling): Alive, yes… but also loud, crowded, and always rushing. I’d rather live in a small village.

Nerea (laughing): A village? What would you even do there all day?

Silvia: Plenty! Walk in nature, talk to neighbors, breathe clean air. Life feels real there.

Nerea: But I love the city’s energy! So many things to do — theaters, shops, concerts!

Silvia: And in a small village, you have time to think, to listen, to just be.

Nerea (teasing): You and your peace and quiet!

Silvia (laughing): And you and your noise and lights!

Nerea (pausing): Still… cities can be stressful. Always traffic,... Continue reading "The Great Debate: City Energy vs. Countryside Calm" »

Microbiology Lab Fundamentals: Growth, Metabolism, Genetics

Posted by Anonymous and classified in Biology

Written on in English with a size of 19.49 KB

Lab 8: Temperature and Microbial Growth

Key Concepts

  • Psychrophiles grow best between 0–20°C. Often found in cold environments like glaciers.
  • Mesophiles prefer 20–45°C. These include human pathogens like E. coli.
  • Thermophiles thrive at 55°C or higher. They are often found in hot springs.

Materials and Their Functions

  • Tryptic Soy Broth (TSB): A nutrient-rich medium that supports bacterial growth.
  • Incubators set to different temperatures (4°C, 25°C, 37°C, 55°C): Used to simulate environmental conditions.
  • Spectrophotometer (OD600): Measures turbidity (cloudiness) of a culture to estimate cell density.
  • Classification by growth: “+++” indicates heavy growth; “0” means no growth.

In this lab, students investigated how temperature affects... Continue reading "Microbiology Lab Fundamentals: Growth, Metabolism, Genetics" »