Aarushhh/wikipedia-simple-splitted huggingface dataset:
Hilbert's paradox of the Grand Hotel is a mathematical paradox named after the German mathematician David Hilbert. Hilbert used it as an example to show how infinity does not act in the same way as regular numbers do.

The paradox 
Normal hotels have a set number of rooms. This number is finite. Once every room has been assigned to a guest, any new guest that wants a room and does not have one yet cannot be served - in other words, the hotel is fully booked.
Now suppose that there is a hotel that has an infinite number of rooms. As a convenience, the rooms have numbers, the first room has the number 1, the second has number 2, and so on. If all the rooms are filled, it might appear that no more guests can be taken in, as in a hotel with a finite number of rooms. This is wrong, though. A room can be provided for another guest. This can be done by moving the guest in room 1 to room 2, the guest in room 2 to room 3, and so on. In the general case, the guest in room n will be moved to room n+1. After all guests have moved, room 1 is empty, and the new guest now has a room to occupy. This shows how we can find a room for a new guest even if the hotel is already full, something that could not happen in any hotel with a finite number of rooms.
In case of infinitely new guests 
Another thing that can be done with this imaginary hotel is to double the number of people inside, again when all the rooms are already full. This is done by asking each guest to multiply their room number by two and move to that room. (If their previous room number was n, this time they would move to room number 2n.) This would send the guest in room 1 to room 2, the guest in room 2 to room 4, the guest in room 3 to room 6, the guest in room 4 to room 8, and so on. After finishing, we find that all the rooms with the odd numbers are empty. Then we can put an infinite number of guests into these empty rooms. Now the number of guests in the hotel has been doubled without making the hotel bigger.

If infinite groups of infinite guests come 
The guest at room 11 would move to room 101.
The second person of group 5 (Address 5-2) would go to room 25.
This is not really a paradox, it is only counterintuitive. In a normal hotel, with a finite number of rooms, the number of odd-numbered rooms, is smaller than the total number of rooms. In Hilbert's Hotel this does not seem to be the case.

In case of infinite vehicles of infinite groups of infinite guests
The guest 1 of group 2 of vehicle 1 (1-2-1) goes to room 121.

Further layers of infinity

Infinite aircraft carriers of the same infinite vehicles
Address 4-7-7-4 goes to room 4774.

Infinite spacecraft of the same infinite aircraft carriers.
Address 0-1 (hotel dweller) stays because 1-0-0-0-1 moves to room 10,001.

and so on.

Infinite layers of nesting
Each pod holds 10 people.

Each megapod holds 10 pods. (100 people)

Each supermegapod holds 10 megapods. (1,000 people)

Each superdupermegapod holds 10 supermegapods.

Each ultrasuperdupermegapod holds 10 superdupermegapod.

Each ultrasuperduperubermegapod holds 10 ultrasuperdupermegapods. (1,000,000 people)
And so on.
This assumes that there is never an infinitieth layer. (The main ship)

Analysis 
Hilbert's paradox is a veridical paradox: it leads to a counter-intuitive result that is provably true. The statements "there is a guest to every room" and "no more guests can be accommodated" are not equivalent when there are infinitely many rooms. An analogous situation is presented in Cantor's diagonal proof.
At first, this state of affairs might seem to be counter-intuitive. The properties of "infinite collections of things" are quite different from those of "finite collections of things". The paradox of Hilbert's Grand Hotel can be understood by using Cantor's theory of transfinite numbers. In an ordinary (finite) hotel with more than one room, the number of odd-numbered rooms is obviously smaller than the total number of rooms. However, in Hilbert's aptly named Grand Hotel, the quantity of odd-numbered rooms is not smaller than the total "number" of rooms. In mathematical terms, the cardinality of the subset containing the odd-numbered rooms is the same as the cardinality of the set of all rooms. Indeed, infinite sets are characterized as sets that have proper subsets of the same cardinality. For countable sets (sets with the same cardinality as the natural numbers) this cardinality is .
Put differently, for any countably infinite set, there exists a bijective function which maps the countably infinite set to the set of natural numbers, even if the countably infinite set contains the natural numbers. For example, the set of rational numbers—those numbers which can be written as a quotient of integers—contains the natural numbers as a subset, but is no bigger than the set of natural numbers since the rationals are countable: there is a bijection from the naturals to the rationals.

References

Other websites 
The Infinite Hotel Paradox - Jeff Dekofsky - TED-Ed Lessons

Mathematical paradoxes
In mathematics, the opposite or additive inverse of a number  is a number  which, when added to , results in 0. The opposite of  is . For example, −7 is the opposite of 7, because .

Definition 
A number  is called an opposite number of another number  if . By definition,  is the opposite number of . For example,  is the opposite number of  and vice-versa. This is because  

Opposite numbers are also known as additive inverses.
Properties 
The opposite numbers satisfy the properties listed below.
 The opposite of 0 is 0.
 Two opposite numbers have the same absolute value. This follows from the fact that the  is the opposite number of  and both have the same absolute value .
 The opposite of a positive number is the negative version of the number. The opposite of a negative number is the positive version of the number. 
 opposite numbers are located in the opposite direction on a number line having the same distance from the origin. That is, they are symmetric about the origin on a number line.
 The sum of two opposite numbers is always zero, because  
 The division of two non-zero opposite numbers is always , because  
 Each number has a unique opposite number.

Related pages 

 Addition
Reciprocal
Absolute value
Operation (mathematics)

References 

 

Numbers
Arithmetics
Algebra
An n-th root of a number r is a number which, if n copies are multiplied together, makes r. It is also called a radical or a radical expression. It is a number k for which the following equation is true:

(for the meaning of , see Exponentiation.)

We write the nth root of r as . If n is 2, then the radical expression is a square root. If it is 3, it is a cube root. Other values of n are referred to using ordinal numbers, such as fourth root and tenth root.

For example,  because . The 8 in that example is called the radicand, the 3 is called the index, and the check-shaped part is called the radical symbol or radical sign.

Roots and powers can be changed as shown in .

The product property of a radical expression is the statement that . The quotient property of a radical expression is the statement ., b != 0.

Simplifying 

This is an example of how to simplify a radical.

If two radicals are the same, they can be combined. This is when both of the indexes and radicands are the same.
This is how to find the perfect square and rationalize the denominator.

Related pages
 Geometric mean
 Rationalization (mathematics)
 Square number

References

Mathematics
The Isle of Portland is an island in Dorset in the south of England. Portland is south of the resort of Weymouth. 13,000 people live there. It is where the famous Portland limestone was originally found.

In 2012, the sailing in the Olympics took place on Portland and in Weymouth.

References

Other websites 

Dorset
Islands of England
Weymouth is a resort town in Dorset on the south coast of England. 52,000 people live in the town. Thousands of tourists have holidays there, because it is by the sea. In summer it is sometimes sunny and warm and there is lots to do. The sailing in the 2012 Summer Olympics were held in Weymouth and on the Isle of Portland nearby.

Weymouth, Dorset
Chrysanthemums are a genus (Chrysanthemum) of about 30 species of perennial flowering plants in the family Asteraceae, from Asia and northeast Europe.

References and other websites 
Germplasm Resources Information Network: Chrysanthemum 
Painting of Chrysanthemums
Chrysanthemum Gardening and care
ICBN: List of conserved genera (scroll down for Chrysanthemum)

Flowers
Asteraceae
A flagship is the ship used by the officer who commanded a group of naval ships. The term comes from the custom of the commanding officer to fly a special flag to show he was present.

Used in this way, "flagship" is normally a temporary name; the flagship is wherever the officer is flying his flag. However, admirals have always needed a special place; a meeting room large enough to hold all the captains of the fleet, and a place for the admiral's staff to make plans and draw up orders.

Over the years, the term "flagship" has been borrowed by other industries. These include broadcasting, automobiles, cell phones, and others to mean their core products or services.

References 

Ships
The Eurasian magpie or common magpie (Pica pica) is a bird that lives in Europe, much of Asia, and northwest Africa. It is one of several birds in the crow family named as magpies.

In Europe, "magpie" is used by English speakers to call the European magpie; it is the only magpie in Europe outside the Iberian Peninsula.

Related pages

General licences under the Wildlife & Countryside Act 1981

Other websites 
 European Magpie videos  on the Internet Bird Collection
 Avibase 

Corvids
Sui generis (pronounced  or ) is a term from Latin. It can be translated to Of (his/her/its) own kind. It basically means that something has VERY special characteristics. They are so special, that the thing cannot really be compared to anything else. It is used in various contexts. The term was invented by philosophers. What they originally wanted to say was that an idea is so specific as to be unique, that it cannot really be part of a broader concept.

Law
When lawyers talk about something being sui generis, they mean that something is unique.  It cannot be compared. With intellectual property, a design can be sui generis.

Political sciences
The European Union is something that has come to be in the last few years. In some ways it is like state in others like a confederation of states or an international organisation. It is mostly classified as sui generis.
Sociology
In the sociology of Emile Durkheim, sui generis is used to illustrate his theories on social existence. He says that society, as it was there before any living individual was born, is independent of all individuals. His sui generis (its closest English meaning in this sense being 'independent') society will furthermore continue its existence after the individual ceases to interact with it.

Examples in media
Meryl Streep was praised in a Wall Street Journal review of The Devil Wears Prada: "(her) pitch-perfect portrayal of Miranda is sui generis, with a dramatic existence of its own, as unique and memorable as, say, a Bette Davis character."

Martin Kettle in The Guardian said about hung parliaments: "Each is sui generis, dependent on the particular parliamentary arithmetic, inter-party momentum and surrounding political circumstances."
Slate has used the term several times; one article discussed the unique variations of French Rose Champagne: "Grower Champagnes are wines made by small farmers in the Champagne region who, bucking convention, choose to craft their own wines rather than sell their grapes to the major Champagne houses. Typical of farmer fizzes, the grower rosés are utterly sui generis—in a few cases almost freakishly so."

A CNN The Marquee post said about James Brown, "I can't even begin to talk about his importance. He was sui generis."

Political commentator Dick Morris referred to the intense public interest in the 2008 US Presidential race as "clearly sui generis, and anything can happen."

References

Legal terms
Latin words and phrases
A regular polygon is a shape that can be drawn on a flat surface. It has sides that are all the same length, and its angles are all the same. In other words, a polygon which is both equilateral (which means all its sides have the same length) and equiangular (which means that all its angles are the same) is a regular polygon. It always has the same number of edges and points.

A polygon is also convex if there aren't any two points within it that can't be connected with a straight line, where the entire straight line is also in it. An example of a concave shape is a five-pointed star. It's concave because you can connect two of the points of a star with a straight line, and most of the straight line doesn't go through the star. If a five-pointed star is both equilateral and equiangular, it is also a regular polygon, but it isn't a convex one. All regular concave polygons are stars.
Examples
The simplest examples of regular convex polygons are:
Polygons with more sides look more like circles. A polygon with an infinite number of sides is called an apeirogon. Polygons can be described in text by a special symbol called a Schläfli symbol. This symbol is written as curly brackets, with some numbers inside it, like {3}. {3} is a triangle. The number inside can also be a fraction. A Schläfli symbol of {5/2} is a five-pointed star.
Properties 
Most mathematical objects have things that can be said about them that are always true. These are called properties. All polygons (convex and star polygons) can be rotated in place by some angle and still look the same—in other words, they're all rotationally symmetric. For example, a square could be rotated a quarter turn, and it would look the same as before. Another way of seeing this property is that any polygon can have a circle drawn around it, touching all its points, and the polygon's points are evenly spaced around the circle. A polygon can also have a circle drawn inside it, touching all its edges (but not overlapping), and the places where the circle touches the polygon are also evenly spaced. The centers of the two circles drawn are in the same place. This proves that a regular polygon is rotationally symmetric.
The circle outside the polygon is called circumscribed, and the circle inside the polygon is called inscribed. Any polygon where a circle circumscribes all its points is called a cyclic polygon. All regular polygons are cyclic, but not all cyclic polygons are regular.
Polygons
Straightedge and compass construction, also known as ruler-and-compass construction, is drawing of lengths, angles or shapes using only a ruler and compass. 

Some things cannot be drawn this way.  For example, there are only 32 regular polygons with an uneven number of sides which are known to be constructible.  It has been proven that a square with the same area as the area of a circle cannot be constructed.  This is called "Squaring the circle".

Geometry
A carnation is a type of flower. It has been grown for so many years, we are not sure where it came from.

Related pages
 Sweet William

Caryophyllaceae
Air Force One is the official air traffic control call sign aircraft carrying the president of the United States. Air Force One is usually always referred to any aircraft the president and his staff travels on. The official name of the plane is the SAM 2900 and VC-25.

Air Force One is one of the most recognizable symbols of the presidency not just in American culture but across the world. Emblazoned with the words “United States of America,” the United States flag, and the Seal of the President of the United States. Air Force One has an undeniable and amired presence wherever it goes and flies to.

History 
Air Force One is maintained and operated by the Presidential Airlift Group, part of the White House Military Office. The Airlift Group was founded in 1944 as the Presidential Pilot Office at the direction of President Franklin D. Roosevelt.
For the next 15 years, various propeller-driven aircraft served until President Dwight D. Eisenhower flew to Europe aboard VC-137A, a Boeing 707 Stratoliner, in August 1959.

In 1962, President John F. Kennedy became the first president to fly in a jet specifically built for presidential use  a modified Boeing 707 until it retired in 1990.

The current presidential aircraft, Boeing 747-200B, became the new and modified presidential plane in 1990, when President George H.W. Bush became the first president to ride on the aircraft.
Layout and amenities 
 Inside, the president and his staff members can enjoy 4,000 square feet of floor space on three floors, including an extensive suite for the president that features a large office, lavatory, conference room, gym, and a large bathroom.
 Air Force One includes a medical suite that can function as an operating room, and a doctor is permanently on board. The plane’s two food preparation galleys can feed 100 people at a time. It can also prepare up to 2,000 meals
 Air Force One also has quarters for those who accompany the president, including senior advisors, Secret Service officers, traveling press, and other guests. Several cargo planes typically fly ahead of Air Force One to provide the president with vehicles and services needed in remote locations.
 The aircraft has two lower decks so stairs won't be an issue in foreign countries.

 It has 85 telephones for government secured lines and regular use.
 It has 20 television sets.
 All of it's windows are bulletproof and armored.
References 

United States Air Force

Individual aircraft
Origins of the legends 
People have come up with different explanations for the incubus legends. In the Middle Ages, people worried a lot about sin, especially sexual sins of women. Victims may have been experiencing waking dreams or sleep paralysis. Also, nocturnal arousal, orgasm or nocturnal emission could be explained by the idea of creatures causing an otherwise guilt-producing and self-conscious behavior. The influence of incubi could also have been used to explain how pregnancies happen outside marriage; such pregnancies were often "unexplainable".and unnoticed
Ancient and religious descriptions 
One of the earliest mentions of an incubus comes from Mesopotamia on the Sumerian kings' list, ca. 2400, where the hero Gilgamesh's father is listed as Lilu (Lila). It is said that Lilu disturbs and seduces women in their sleep, while Lilitu, a female demon, appears to men in their erotic dreams. Two other demons appear as well: Ardat lili visits men by night and bears ghostly children from them. Irdu lili, is the male counterpart to Ardat lili. He visits women by night. These demons were originally storm demons. Because the etymology was interpreted wrongly, they were later seen as night demons. Also considered to be vampires which is another form of a demon that is said to drink blood from its victims.
Incubi and succubi were said by some not to be different sexes, but the same demon able to change its sex. A succubus would be able to sleep with a man and collect his sperm, and then transform into an incubus and use that seed on women. Their offspring were thought to be supernatural in many cases, even if the actual genetic material originally came from humans.

Many tales claim that the incubus is bisexual, but some indicate that it is strictly heterosexual and finds attacking a male victim either unpleasant or detrimental. There are also many stories involving the attempted exorcism of incubi or succubi who have taken refuge in the bodies of men or women.

Incubi are sometimes said to be able to conceive children. The half-human offspring of such a union is sometimes referred to as a cambion. The most famous legend of such a case includes that of Merlin, the famous wizard from Arthurian legend.
According to the Malleus Maleficarum, exorcism is one of the five ways to overcome the attacks of Incubi, the others being Sacramental Confession, the Sign of the Cross (or recital of the Angelic Salutation), moving the afflicted to another location, and by excommunication of the attacking entity, "which is perhaps the same as exorcism."  On the other hand, the Franciscan friar Ludovico Maria Sinistrari stated that incubi "do not obey exorcists, have no dread of exorcisms, show no reverence for holy things, at the approach of which they are not in the least overawed."

References 

Demons
A Commonwealth realm is a country in the Commonwealth of Nations which has King Charles III as monarch. They include his home country of the United Kingdom and many of its former colonies or territories. As of 2023, there are 15 commonwealth realms:

In each of the countries outside the UK, the King appoints a Governor-General to represent him, who, after consulting with the government of the realm, has all of the powers and duties of the Monarch. Usually the Governor-General signs all acts of parliament into law, but can wait and ask the King for advice or wait for him to sign the act himself.  This happened in 1982 when Queen Elizabeth signed the important Canadian Charter of Rights and Freedoms during a visit to Ottawa, and the Australia Act 1986 in Canberra.
Although King Charles III is monarch of many countries, the British government has no power in the other realms, just as the governments of the other realms have no power in the UK. This is why each realm decides on the Monarch's official title. Usually it is "Queen/King of (realm) and Her/His other Realms and Territories, Head of the Commonwealth". But two countries mention the UK in their title for the Queen: Grenada uses "Queen of the United Kingdom of Great Britain and Northern Ireland and of Grenada and Her other Realms and Territories, Head of the Commonwealth", while Canada uses the old-fashioned form, which reads "by the Grace of God, of the United Kingdom, Canada and Her other Realms and Territories Queen, Head of the Commonwealth, Defender of the Faith." Not all countries use the title Defender of the Faith.


Other websites
 The Commonwealth Secretariat Official site
 The Commonwealth - UK Government site

Commonwealth
 United Commonwealth  Main All-Commonwealth group
Australia
 Australian Monarchist League (traditionalist constitutional monarchists)
 No Republic - Australians for Constitutional Monarchy (Moderate constitutional monarchists)

Canada
 Canadian Monarchy - The Official Site 
 Canadian Monarchist ONLINE
 Monarchist League of Canada

New Zealand
 Monarchist League of New Zealand 

History of the United Kingdom
 
British monarchy
A Dashiki is a loose fitting, brightly coloured garment associated with African culture. It is also associated with the counterculture of the 1960s in the United States. The most popular styles cover the top half of the body. It originated in West Africa. A common form is a loose-fitting pullover garment, with an ornate V-shaped collar. It often has an embroidered neck and sleeve lines. There are both casual and formal versions.

History 
The dashiki originated in West Africa and East Africa. Twelfth and thirteenth centuries burial mounds in Mali (West Africa) have revealed versions of dashikis. Dashikis were worn by both men and women. They may have been influenced by the thawb worn by Arabs who came to the region. Both garments keep the wearer cool in the hot African climate. The dashiki was worn as a work shirt in the shorter version. Another much longer version was called the grand boubou. It is also similar to the kaftan. All three are common to West Africa.
1960s US counterculture 
The dashiki became popular in the hippie culture of the 1960s. Peace Corps members returning from Africa brought back dashikis. African diplomats to the United Nations in New York were often seen and photographed wearing colorful dashikis. Dashikis were seen as a symbol of support for black racial struggles. Groups like the Black Panthers wore the Dashiki as a symbol of their black heritage. The Afro hairstyle, faded blue jeans and the Dashiki were all popular expressions of the Black is beautiful cultural movement.

Musical groups 
 
Many of the rock groups of the 60s and 70s wore Dashikis. But black performers of the 60s 70s preferred the more conventional suit and tie look. But in the 80s several black groups wore the dashiki to show their heritage. One South African vocal group, 'Ladysmith Black Mambazo', wore dashikis extensively. This identified them more as Africans than Zulus.

References

Other websites 

 Dashikis 
 Dashiki

Tops (clothing)
African culture
The Colorado Avalanche are an American ice hockey team in the National Hockey League (NHL). They play their home games at Ball Arena in Denver, Colorado. They play in the Central Division of the Western Conference. The team has won the Stanley Cup championship three times: in 1996, 2001, and in 2022.

References

Other websites
Official website

Colorado Avalanche
1972 establishments in the United States
Avalanche
The Battle of Midway was an important naval battle of World War II, between the United States and the Empire of Japan. It took place from 4 June 1942 to 7 June 1942. This was about a month after the Battle of the Coral Sea, and six months after the Japanese attack on Pearl Harbor.

The United States Navy defeated a Japanese attack against Midway Atoll (northwest of Hawaii) and destroyed four Japanese aircraft carriers and a heavy cruiser.

The battle was a decisive victory for the Americans. It was the most important naval battle of the Pacific area in World War II. The battle weakened the Imperial Japanese Navy for the rest of the war. Japan could not build up its forces again. The United States replaced their lost ships and planes with better ones very quickly. Japan could only make a few poor quality replacements.
The Japanese planned to bring America's carriers into a trap and sink them. The Japanese also tried to take Midway Atoll to build defenses far from their homeland and prepare to invade Fiji, Samoa, and Hawaii.

The Midway operation, like the attack on Pearl Harbor, was made to destroy the American strength in the Pacific Ocean. This way, Japan could become the biggest power in the area and unify Asia under its control. It was also hoped that another defeat would force the U.S. to ask for peace soon.

After the defeat, Imperial Japanese Navy forces retired. Japan lost four out of their six carriers, and hundreds of their best air pilots. This stopped the expansion of the Japanese Empire in the Pacific, and the Americans began to slowly advance towards Japan.

Background
Background

Japan had reached its first goals quickly, taking the Philippines, Malaya, Singapore, and the Dutch East Indies (now Indonesia).  This gave Japan petroleum, which it needed to make more war. Planning for a second part of the operations started in January 1942. However, disagreements between the Imperial Army and Imperial Navy, and among naval commanders, prevented finishing the plan until April 1942. Admiral Yamamoto said he would quit if his plan for the Central Pacific was not accepted. It was accepted.
Yamamoto's main goal was to destroy America's carrier forces, which he saw as the main threat to the Pacific campaign. This concern was increased by the Doolittle Raid on 18 April 1942. In this raid, 16 US Army Air Forces B-25 Mitchell bombers launched from  bombed targets in Tokyo and several other Japanese cities.  The raid, while militarily unimportant, showed that American bombers could reach Japanese territory. This and other successful raids by American carriers showed that they were still a threat.

Yamamoto thought that another attack on the U.S Naval base at Pearl Harbor would make all of the American fleet to sail out to fight, including the carriers. However, because of the many American land-based airplanes on Hawaii, he thought that it was too risky to attack directly. Instead, he decided to attack Midway, a tiny atoll at the northwest end of the Hawaiian Island chain, approximately  from Oahu. The Japanese didn't need Midway but they felt the Americans would try hard to defend it.
The U.S. did consider Midway to be important. After the battle, they set up a submarine base on Midway. That meant submarines operating from Pearl Harbor could refuel and get new supplies, so they could go  farther west. Midway's airstrips were also used for bomber attacks on Wake Island.

Yamamoto's plan: Operation MI 

Like most Japanese naval planning during World War II, Yamamoto's battle plan was very complex.  His was also based on incorrect (wrong) information.  He thought that  and  were the only carriers available to the U.S. Pacific Fleet. In May 1942, during the Battle of the Coral Sea,  had been sunk and  so badly damaged that the Japanese thought she had been sunk. The Japanese also knew that  was being repaired on the US West Coast after getting torpedo damage from a submarine.  and  were in the Atlantic, but the Japanese were not sure this was so.
Yamamoto thought that the Americans had been demoralized by their defeats in the last six months.  He thought a trick would lure the U.S. fleet into a dangerous situation. He spread out his ships, especially his battleships, so that they would be hard to find. Yamamoto's battleships and cruisers went behind Vice-Admiral Chūichi Nagumo's carrier force by several hundred miles.  Japan's heavy surface forces would wait for the U.S. ships to come to defend Midway, and destroy them.

The plan was for Nagumo's carriers to cause so much harm to US ships that the Japanese could fire on them by daylight.

Yamamoto did not know that the U.S. had broken the main Japanese naval code. Yamamoto's choice to spread out his ships meant that none of his groups of ships could support each other. The only warships larger than the 12 destroyers that protected Nagumo's fleet were two battleships, two heavy cruisers, and one light cruiser.
Aleutian invasion 
The Japanese attacks in the Aleutian Islands (Operation AL) took away yet more ships that could have attacked Midway.  Many histories once saw the Aleutians attack as a feint to draw American forces away.  Early twenty-first century research shows that AL was supposed to be launched at the same time as the attack on Midway. However, a one-day delay in the sailing of Nagumo's ships resulted in Operation AL beginning a day before the Midway attack.

Prelude to battle

American reinforcements
To battle with an enemy expected to have four or five carriers, Admiral Chester W. Nimitz, Commander in Chief, Pacific Ocean Areas, needed every U.S. carrier he could get. He already had Vice Admiral William Halsey's two-carrier (Enterprise and Hornet) force. Halsey was sick with psoriasis and had to be replaced by Rear Admiral Raymond A. Spruance. Nimitz also called back Rear Admiral Frank Jack Fletcher's force, including the carrier Yorktown (which had major damage at Coral Sea), from the South West Pacific Area. It reached Pearl Harbor just in time to sail.

The damaged Yorktown however, was not completely crippled. The Pearl Harbor Naval Shipyard worked all day and all night, and in 72 hours she was ready to battle for two or three weeks. Her flight deck was patched, sections of internal frames were replaced, and several squadrons of aircraft were taken from Saratoga. The pilots did not get time to train. Repairs on Yorktown continued even as she sailed out.
On Midway, by 4 June the USN had stationed four groups of PBYs—31 aircraft in total—for long-range reconnaissance duties, and six new Grumman TBF-1 Avengers. The Avengers were taken from Hornets VT-8. The Marine Corps had 19 Douglas SBD Dauntlesses, seven Grumman F4F-3 Wildcats, 17 Vought SB2U-3 Vindicators, and 21 Brewster F2A-3s. The USAAF sent a group of 17 B-17 Flying Fortresses and eight B-26 Marauders with torpedoes: in total 126 aircraft.

Japanese shortcomings 

During the Battle of the Coral Sea one month earlier, the Japanese light carrier Shōhō had been sunk and the fleet carrier  had three bomb hits, and was in drydock undergoing repairs. Although the carrier  was undamaged, she had lost almost half her airplanes and was in port in Kure awaiting new planes and pilots. No new pilots were available because none had been trained. Flight instructors were used in an effort to make up the missing aircrew.
Japan's two most advanced aircraft carriers were not available and Admiral Nagumo would therefore have only four fleet carriers:  and ;  and .  At least part of this was due to overwork; Japanese carriers had been constantly operating since 7 December 1941, including raids on Darwin and Colombo.

The main Japanese carrier-based aircraft were the Aichi D3A1 dive bomber and the Nakajima B5N2, which was used either as a torpedo bomber or as a bomber.  However, production of the D3A had been reduced, while production of the B5N had been stopped.  None were available to replace losses.  In addition many of the aircraft being used during the June 1942 operations had been operating since late November 1941; many were almost worn out and had become increasingly unreliable.  These factors meant that all carriers of the Kido Butai had fewer aircraft than normal and there were not enough spare aircraft or parts. I
Japan's main carrier fighter was the fast Mitsubishi A6M2 "Zero".
Japanese scouting before the battle was disorganized. A line of Japanese submarines was late getting into position. This let the American carriers reach their meeting point northeast of Midway (known as "Point Luck") without being found by the subs. A second attempt at scouting, using four-engine Kawanishi H8K flying boats to fly to Pearl Harbor prior to the battle and see whether the American carriers were there did not work out because Japanese subs could not refuel the planes. Japan did not know where the American carriers were before the battle.

Japanese radios did pick up more American submarine activity and messages. Yamamoto knew this before the battle, but Japanese plans were not changed. Yamamoto, at sea on , assumed that Nagumo had received the same message from Tokyo, and he did not send the message, because he did not want the US to hear the message. Nagumo's radio antennas could not get the message from Tokyo.
Allied code-breaking
Admiral Nimitz had one advantage: code experts had broken the Japanese Navy's JN-25b code. Since the early spring of 1942, the US had been decoding messages stating that there would soon be an operation at objective "AF". They guessed that it was Midway and sent an uncoded radio message that Midway needed fresh water. The code breakers then picked up a Japanese message that "AF was short on water." HYPO was also able to determine the date of the attack as either 4 or 5 June, and to tell Nimitz exactly which Japanese ships were coming. Japan had a new codebook, but it was not used for several days. The new code, which had not yet been figured out, was used shortly before the attack began, but the important information had already been figured out.
Americans knew where, when, and in what strength the Japanese would arrive at Midway. Nimitz knew that the Japanese had ruined their advantage in number of ships by dividing their ships into four groups, all too separated to be able to support each other. Nimitz calculated that the aircraft on his three carriers, plus those on Midway Island, gave the U.S. rough parity with Yamamoto's four carriers, mainly because American carrier air groups were larger than Japanese ones. The Japanese, by contrast, remained almost totally unaware of their opponent's true strength and dispositions even after the battle began.

Battle
Battle

Initial air attacks 
At about 09:00 on 3 June, a US Navy patrol plane spotted the Japanese Occupation Force  to the west-southwest of Midway. Three hours later, the Americans found the Japanese transport group  to the west. They attacked, but none of the bombs hit and no major damage resulted. Early the following morning the Japanese oil tanker Akebono Maru was hit by a torpedo from an attacking PBY. This was the only successful air-launched torpedo attack by the U.S. during the entire battle.

At 04:30 on 4 June, Nagumo launched his attack on Midway. It consisted of 36 dive bombers 36 torpedo bombers, escorted by 36 Mitsubishi Zero fighters. At the same time he launched a defensive combat air patrol. His eight search planes launched 30 minutes late.

Japanese reconnaissance plans were poor, with too few aircraft to cover the search areas. Yamamoto's decisions had now become a serious problem.
Of the 108 Japanese aircraft involved in this attack, 11 were destroyed, 14 were heavily damaged, and 29 were damaged. The initial Japanese attack did not destroy Midway: American bombers could still use the airbase to refuel and attack the Japanese invasion force. Most of Midway's land-based defenses were intact. Another air attack to destroy Midway's defences would be necessary if troops were to be able to go ashore by 7 June.

American bombers based on Midway made several attacks on the Japanese carrier fleet. These included six Grumman Avengers from the s VT-8 (Midway was the first combat mission for the VT-8 airmen, and it was the first combat of the TBF), Marine Scout-Bombing Squadron 241 (VMSB-241), consisting of eleven SB2U-3s and sixteen SBDs, plus four USAAF B-26s, armed with torpedoes, and fifteen B-17s. The Japanese fought off these attacks. The US lost two fighters, five TBFs, two SB2Us, eight SBDs and two B-26s.
One B-26, after being seriously damaged by anti-aircraft fire, dove straight toward the Akagi. The plane just missed the carrier's bridge, which could have killed Nagumo and his command staff. This may have made Nagumo decide to launch another attack on Midway, against Yamamoto's order to keep the reserve force for anti-ship operations.

Nagumo's decision 
Admiral Nagumo had kept half of his aircraft in reserve. These were two squadrons of dive bombers and torpedo bombers. At 07:15 Nagumo ordered his reserve planes to be re-armed with bombs for use against land targets. At 07:40 a scout plane from Tone saw a big American naval force to the east. It seems that Nagumo did not receive the report until 08:00. Nagumo reversed his order, but it took 40 minutes before Tones scout finally radioed that there was a carrier in the American force. This was one of the carriers from TF 16; the other carrier was not sighted.
Nagumo was now unsure of what to do. Rear Admiral Tamon Yamaguchi recommended that Nagumo strike with the forces at hand: 18 Aichi D3A dive bombers each on Sōryū and Hiryū, and half the cover patrol aircraft. Nagumo's opportunity to hit the American ships, however, was now limited. The Midway strike force would be returning shortly and needed to land or crash into the sea. Because of the constant flight deck activity, the Japanese did not get their reserve planes on the flight deck for launch. The few aircraft that were ready were defensive Fighter aircraft. Launching aircraft would have required at least 30 to 45 minutes. By launching right away, Nagumo would be using some of his reserve without proper anti-ship weapons. He had just seen how easily unescorted American bombers had been shot down. Poor discipline caused many of the Japanese bombers to get rid of their bombs and attempt to fight intercepting F4Fs
. Japanese carrier rules preferred full strikes, and since Nagumo did not know the American force included a carrier, his response followed Japanese rules. In addition, the arrival of another American air strike at 07:53 made Nagumo want to attack the island again. Nagumo decided to wait for his first strike force to land, then launch the reserve, which would by then be armed and ready.
Fletcher's carriers had launched their planes beginning at 07:00, so the aircraft that attacked Nagumo were already on their way. There was nothing Nagumo could do about it. This was the flaw with Yamamoto's plans.

Attacks on the Japanese fleet

The Americans had already launched their carrier aircraft against the Japanese. Admiral Fletcher, in command aboard Yorktown, and having PBY sighting reports from the early morning, ordered an attack on the Japanese as soon as possible. He held Yorktown in reserve in case any other Japanese carriers were found. (Fletcher's directions to Spruance were sent by Nimitz, who had remained ashore.)

Spruance thought that even though the range was far, an attack could succeed. He gave the order to launch the attack at around 06:00. Fletcher, upon completing his own scouting flights, followed at 08:00 from Yorktown.
Admiral Fletcher, commanding the Yorktown task force, along with Captain Elliott Buckmaster,Yorktowns commanding officer, and their staffs had experience in doing a full strike against an enemy force in the Coral Sea. But they could not pass on what they had learned to Enterprise and Hornet which were ordered to launch the first strike. Spruance ordered the aircraft to go to the target right away, since destroying enemy carriers was important to the safety of his ships. Spruance decided it was more important to attack as soon as possible, rather than coordinate the attack by aircraft of different types and speeds (fighters, bombers, and torpedo bombers). American squadrons went to the target in several different groups. He hoped that he would find Nagumo with his flight decks full of planes.
American carrier aircraft had difficulty locating the target. The strike from Hornet, led by Commander Stanhope C. Ring, did not fly in the right direction. Air Group Eight's dive bombers missed the Japanese carriers. Torpedo Squadron 8 flew in the correct direction. However, the 10 F4Fs from Hornet had run out of fuel and had to crash into the ocean. Waldron's squadron saw the enemy carriers and began attacking at 09:20, followed by Torpedo Squadron 6 (VT-6, from Enterprise) whose Wildcat fighter escorts also ran low on fuel and had to turn back at 09:40. Without fighter escort, all fifteen TBD Devastators of VT-8 were shot down without being able to do any damage, with Ensign George Gay the only survivor. VT-6 lost 10 of their 14 Devastators, and 10 of Yorktown's VT-3's 12 Devastators were shot down with no hits. Part of the problem was the poor performance of the Mark 13 torpedoes
. Senior Navy and Bureau of Ordnance officers never asked why six torpedoes, released so close to the Japanese carriers, produced no hits. The Japanese combat air patrol, flying Mitsubishi A6M2 Zeros shot down the unescorted, slow, under-armed TBDs. A few TBDs managed to get close enough to drop their torpedoes and shoot their machine guns at the enemy ships. This made the Japanese carriers to make sharp turns. The TBD Devastator was never again used in combat.
Despite their failure to get any hits, the American torpedo attacks made the Japanese carriers unable to prepare and launch their own strike. They also pulled the Japanese combat air patrol (CAP) out of position. As well, many Zeros ran low on ammunition and fuel. The appearance of a third torpedo plane attack from the southeast by Torpedo Squadron 3 (VT-3 from Yorktown) at 10:00 made the Japanese CAP fly to the southeast corner of the fleet. Better discipline and using more Zeroes for the CAP might have enabled Nagumo to prevent the damage caused by the coming American attacks.
Three squadrons of SBDs from Enterprise and Yorktown (VB-6, VS-6 and VB-3, respectively) were approaching from the southwest and northeast. The two squadrons from Enterprise were running low on fuel because of the time spent looking for the enemy. However, the squadron commander decided to continue the search. He spotted the Japanese destroyer Arashi. It was moving to rejoin Nagumo's carriers after having unsuccessfully depth-charged U.S. submarine . Nautilus had earlier unsuccessfully attacked the battleship . Some bombers were lost from lack of fuel before the attack started.
McClusky's decision to continue the search was a great help to the US carrier task force and the forces at Midway. All three American dive-bombers squadrons (VB-6, VS-6 and VB-3) arrived at the right time to attack. Most of the Japanese CAP were looking for the torpedo planes. Armed Japanese strike aircraft filled the hangar decks, fuel hoses lay on the decks and bombs and torpedoes were near the hangars, making the Japanese carriers very at risk of being damaged.

Beginning at 10:22, the two squadrons of Enterprises air group split up and attacked two targets. By accident, both groups attacked the Kaga. Lieutenant Commander Richard Halsey Best and two other planes headed north to attack Akagi. Coming under an attack from almost two full squadrons, Kaga was hit by four or five bombs, which caused heavy damage and starting fires that could not be put out. One of the bombs landed near the bridge, killing most of the senior officers.
Several minutes later, Best and two planes dove on the Akagi. Although Akagi getting one direct hit (dropped by Lieutenant Commander Best). It struck the deck elevator and went all the way through to the upper hangar deck. It exploded among the armed and fueled aircraft. Another bomb exploded underwater which bent the flight deck and caused rudder damage.

Yorktowns VB-3, commanded by Max Leslie, attacked Sōryū. They got at least three hits and caused a lot of damage. VT-3 targeted Hiryū, but got no hits.

Within six minutes, Sōryū and Kaga were on fire. Akagi was also seriously damaged. The Japanese hoped that Akagi could be saved or towed back to Japan. Eventually, all three carriers were eventually abandoned and sunk.

Japanese counterattacks
Hiryū, the sole surviving Japanese aircraft carrier attacked. Hiryū'''s first attack consisted of 18 dive bombers and six fighter escorts. They followed the retreating American aircraft and attacked the Yorktown, hitting her with three bombs, which blew a hole in the deck, put out her boilers, and destroyed several anti-aircraft guns. Despite the damage, repair teams were able to fix the flight deck and fix several boilers in an hour. Twelve Japanese dive bombers and four escorting fighters were lost in this attack.

Approximately one hour later, Hiryūs second attack was made. It consisted of ten torpedo bombers and six escorting A6Ms. The US repair efforts had been so well done that the Japanese assumed she must be a different, undamaged carrier. In the attack, Yorktown was struck by two torpedoes; she lost all power and developed a tilt to port, which put her out of action. Admiral Fletcher moved his command staff to the heavy cruiser . Neither of the carriers of Spruance's Task Force 16 was damaged.
News of the two strikes, with the reports each had sunk an American carrier (actually Yorktown in both cases), greatly improved morale in the Kido Butai. Its few surviving aircraft were all recovered aboard Hiryū where they were prepared for an attack against what was believed to be the only remaining American carrier.
American counterattack
Late in the afternoon, a Yorktown scout aircraft located Hiryū. Enterprise launched a strike of dive bombers (including 10 SBDs from Yorktown). Despite Hiryū being defended by more than a dozen Zero fighters, the attack by Enterprise was successful: four, possibly five bombs hit Hiryū, leaving her on fire and unable to operate aircraft. (Hornets strike aimed at the escort ships but it did not get any hits.) After hopeless attempts to control the fire, most of the crew remaining on Hiryū were taken off the ship. The rest of the fleet continued sailing northeast to catch the American carriers. Hiryū stayed afloat for several more hours. She was discovered by an aircraft from the light carrier Hōshō. This led to hopes she could be saved or towed back to Japan. However, soon after being spotted, Hiryū sank. Rear Admiral Yamaguchi chose to go down with his ship, costing Japan her best carrier officer.