AI Index Report 2024

More people than ever are studying computer science. Fewer and fewer of them stay to teach it.

Chapter 6 of the AI Index 2024 asks who is learning AI, where, and how that has shifted. Undergraduate computer science in North America hit a record in 2022. Graduate computer science stopped growing. And the flow of talent now runs almost entirely one way — out of the university and into industry. The numbers:

35,666new CS bachelor’s graduates in the US and Canada in 2022 (2010: 9,008)
2,105new CS PhD graduates in 2022 — the highest count since 2010
70.7% of new AI PhDs who took industry jobs in 2022 (2011: 40.9%)
7% of new CS, CE, and information faculty hired out of industry in 2022 (2019: 13%)
2,520English-language AI study programs worldwide in 2023 (2017: 880)
63% of US K–12 teachers who had used ChatGPT by July 2023 (March: 51%)

6.1 — Undergraduate CS keeps climbing. Graduate CS stopped in 2018.

The CRA Taulbee Survey targets 297 PhD-granting CS departments in the United States and Canada; 182 responded, a 61% response rate. It shows a bachelor’s pipeline that has more than tripled in a decade and a graduate pipeline that has been flat for five years.

New CS bachelor’s graduates in North America reached 35,666 in 2022, a 7.9% rise over 2021 and more than three times the 9,008 of 2010. Master’s degrees tell a different story: the total more than doubled over the decade, but it has levelled out since 2018 and slipped 2.5% last year to 14,696. PhDs moved for the first time in a decade — 2,105 new CS doctorates in 2022, the highest count since 2010, after eleven years hovering between roughly 1,770 and 2,000.

The international share fell at every level

  • Bachelor’s: the international share fell from 16.3% in 2021 to 15.2% in 2022 — the first decline in almost eight years. The chapter attributes it partly to study-visa difficulties from the early Trump administration only now showing up in the data, and partly to pandemic travel restrictions.
  • Master’s: the sharpest move in the chapter. The international share dropped 14.8 percentage points in a single year, to 50.40%. International and domestic CS master’s graduates are now split roughly evenly.
  • PhD: down from 68.6% in 2021 to 65.9% in 2022, a slight dip against a decade in which the international share had been rising.
  • This matters because the flat master’s line and the falling international line are the same line. The chapter reads the graduate plateau as a direct reflection of the decline in international master’s students.

Where the new AI PhDs went

In 2011 industry (40.9%) and academia (41.6%) hired new AI doctorates at almost exactly the same rate. By 2022 industry took 70.7% and academia 20.0%. The industry share rose 5.3 percentage points over the past year alone, which the chapter describes as an intensifying brain drain from universities into industry. Government has stayed low and steady at around 0.7% for five years. The three shares do not add to 100 because new AI PhDs who become self-employed, unemployed, or report an “other” status are excluded from the chart.

Where new AI PhDs went in 2022

Share of new AI PhD graduates in the United States and Canada, by sector. Eleven years earlier the first two bars were within a single point of each other, at 40.9% and 41.6%.

Where new AI PhDs went in 2022Industry: 70.7170.71IndustryAcademia: 19.9519.95AcademiaGovernment: 0.760.76Government

Departments are hiring at a decade high — mostly from each other

North American CS, CE, and information departments held 8,738 faculty in 2022, up 7.2% in a year and 42.4% since 2011. They made 915 new hires, the most in a decade. Almost none of them came from industry.

In the United States alone there were 7,084 CS faculty members in 2022, 65.7% of them on the tenure track. That total is 4.4% higher than 2021 and 45.0% higher than 2011. Across the United States and Canada, 915 new faculty were hired in CS, CE, and information disciplines last year, a decade high, and 455 of those positions were tenure track.

Churn, not inflow

  • 43% of 2022’s new faculty appointments came from other academic positions. Because those people vacated posts elsewhere, the vacancy simply moves — the chapter calls it churn within the academic workforce.
  • The share arriving from industry fell to 7%, down from 11% in 2021 and 13% in 2019. The traffic between industry and academia has become close to one-directional.
  • Departures rose sharply, to 405 in 2022 from 303 in 2021. Of those losses, 38.5% left for another academic position and 16.3% for a nonacademic role.
  • International hires among new tenure-track faculty jumped to 19.3% from 13.2% the previous year — the second-highest share of the past decade, behind only 2013.

Failed searches look different than they used to

In 2011, 37% of failed faculty searches ended with no offer being made and 34% with the offer declined. In 2022 only 15% ended with no offer, while 55% involved offers that were turned down. Departments are finding candidates they want and losing them. Pay is part of the backdrop: the median nine-month salary for a full professor in the United States reached 181,610 dollars in 2022, 3.2% above 2021 — below that year’s 7% inflation rate — and 16.4% above 2015, against a 19% rise in prices over the same period.

6.1 — Britain and Germany produce the most graduates. The Nordics produce the most per person.

Informatics Europe collects graduate counts from national statistical offices across informatics, CS, CE, computing, and IT. Rank the countries by headcount and you get one league table; rank them per 100,000 inhabitants and you get a different one.

At bachelor’s level in 2022, the United Kingdom led with roughly 25,040 new graduates, followed by Germany (19,920) and Turkey (13,826), then Poland (9,241) and Italy (8,508). Per 100,000 inhabitants the ordering inverts entirely: Finland leads at 53.38, then Norway (42.63), the Netherlands (38.61), Ireland (38.41), and the United Kingdom (37.36). Growth over the decade was widespread but not universal — Norway added 153%, Turkey 118%, and Switzerland 117%, while Poland, Spain, and the Czech Republic all produced fewer bachelor’s graduates than ten years earlier.

  • Master’s: the United Kingdom again leads with roughly 19,965 graduates, then Germany (11,092), Poland (4,271), and Italy (3,883). Over the decade Germany grew fastest (+259%), then Turkey (+197%) and Spain (+194%).
  • Master’s per capita: Ireland tops the table at 31.19 per 100,000 inhabitants, ahead of the United Kingdom (29.79), Estonia (27.38), and Finland (26.20).
  • PhD: the United Kingdom (1,060) and Germany (910) produced the most, followed by Italy (581) and Spain (479). Turkey saw the sharpest decade growth at +173%.
  • PhD per capita: Finland leads with 2.05 doctorates per 100,000 inhabitants, then Estonia (1.90) and the United Kingdom (1.58). On this measure the past decade went backwards in Germany (-4%), Latvia (-8%), and Ireland (-15%).

One caution the chapter raises about all of this: there is no single term for computer science education across Europe. The same field appears as informatics, CS, CE, computing, IT, ICT, or information science and technology depending on the country, and the European data comes from national statistical offices with broader coverage than the North American survey — so the two datasets should not be compared per capita against each other.

English-language AI study programs worldwide, 2017–23

Studyportals tracks over 200,000 courses at more than 3,750 institutions across 110 countries. The AI count has tripled in six years and rose in every one of them. In 2023 the United Kingdom hosted the most (744), ahead of the United States (667) and Canada (89).

English-language AI study programs worldwide, 2017–232017: 88088020172019: 1450145020192021: 2160216020212022: 2320232020222023: 252025202023

6.2 — Whether an American teenager can take CS still depends on which building they walk into

Code.org data on US high schools. The chapter uses it, explicitly, as a representation of K–12 AI education — there is no separate national count of who learns AI before college.

In 2023, 30 American states required that all high schools offer a foundational course in computer science. Tracked over time, the same Code.org data shows how recent that is: in 2017 only a handful of states supported high school CS at all, and by 2023 36 states allocate funding for it, 30 have adopted a state plan, and 29 require a CS course — roughly two-thirds of states on each measure.

Requiring it and having it are different things. The share of public high schools actually teaching foundational CS ranges from 99% in Maryland and Arkansas and 96% in Nevada down to 28% in Minnesota, 34% in Montana, and 35% in Louisiana. Maryland has more than three times Minnesota’s share of high schools teaching the subject.

AP computer science, tenfold in fifteen years

Approximately 201,000 AP computer science exams were administered in 2022, an 11.1% increase over 2021 and more than a tenfold increase since 2007, when the figure was 19,390. The count covers both AP CS A and AP CS Principles; the latter was first offered in 2017, and the steepest part of the curve starts right around it. Geography again decides the picture: California (33,262), Texas (20,901), and Florida (16,248) led the states, while Montana (39), South Dakota (40), and North Dakota (100) sat at the bottom. Adjusted for population the ranking changes hands entirely — Maryland (126.5 exams per 100,000 inhabitants), New Jersey (112.7), and Massachusetts (92.7) come out on top.

AP computer science exams taken, 2007–22

In thousands. The count barely moved for the first five years — 19.39 in 2007 and 19.39 again in 2010 — then rose every single year after 2011.

AP computer science exams taken, 2007–222007: 19.3919.3920072013: 37.3337.3320132017: 99.8799.8720172020: 179.19179.1920202022: 201.61201.612022

Five things section 6.2 stops to look at

Two highlight boxes sit inside the K–12 section — one on who can reach a computer science classroom at all, one on what American teachers actually started doing with ChatGPT in 2023.

Big schools, small schools

90% of large US high schools offer foundational computer science. 41% of small ones do.

k12access

Suburban schools, and everyone else

67.21% of suburban schools offer foundational CS, against 54.73% urban and 54.62% rural.

k12access

From 33,262 exams down to 39

California administered 33,262 AP CS exams in 2022. Montana administered 39.

k12exams

Teachers picked it up in months

51% of US K–12 teachers had used ChatGPT by March 2023. By July it was 63%.

chatgptteachers

And they liked it more than students did

88% of teachers said ChatGPT has had a positive impact. 79% of students agreed.

chatgptopinion

The chapter in five lines

Headline findings from Chapter 6 · Education.

In 2011 roughly equal shares of new AI PhDs took jobs in industry (40.9%) and academia (41.6%). By 2022, 70.7% joined industry against 20.0% entering academia.
— Chapter 6 · Education
The proportion of new faculty transitioning from industry fell to 7% in 2022, from 11% in 2021 and 13% in 2019 — a progressively lower migration of high-level AI talent back into academia.
— Chapter 6 · Education
Proportionally fewer international CS bachelor’s, master’s, and PhD students graduated in 2022 than in 2021. The drop in the master’s category was especially pronounced, at 14.8 percentage points.
— Chapter 6 · Education
In 2022, 201,000 AP CS exams were administered. Since 2007 the number of students taking these exams has increased more than tenfold.
— Chapter 6 · Education
The number of English-language, AI-related postsecondary degree programs has tripled since 2017, showing a steady annual increase over the past five years.
— Chapter 6 · Education

Read Chapter 6 in full

Chapter 6 (sections 6.1–6.2) with every figure, state map, and citation is free from Stanford HAI. Or head back to the report highlights and the full chapter overview.

Open the AI Index 2024 →