text:
<!doctype html>

  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">

  <title>The World Factbook</title>

  <meta name="description" content="">
  <meta name="viewport" content="width=device-width">

  <link href="../css/fullscreen-external.css" rel="stylesheet" type="text/css">

  <link rel="stylesheet" type="text/css" href="../styles/jquery.ui.core.css">
  <link rel="stylesheet" type="text/css" href="../styles/jquery.qtip.css">
  <link rel="stylesheet" type="text/css" href="../styles/listnav.css"/>
  <link rel="stylesheet" type="text/css" href="../styles/wfb_styles.css">
  <link rel="stylesheet" type="text/css" href="../styles/factbook.css">
  <link rel="stylesheet" type="text/css" href="../styles/navigation.css">
  <link rel="stylesheet" type="text/css" href="../scripts/galleria/themes/classic/galleria.classic.css">

<link rel="stylesheet" type="text/css" href="../scripts/galleria/themes/classic/galleria.classic.css">

  Javascript must be enabled for the correct page display

       	skip to content

          <hgroup>

Central Intelligence Agency

The Work Of A Nation. The Center of Intelligence.

          </hgroup>

Report Threats

رعربيعربي

Contact

              <form id="ciaSearchForm" method="get" action="/search">
                <fieldset>
                  <legend class="visuallyhidden">Search CIA.gov</legend>
                  Search
                  <input name="q" type="text" class="text" id="q" maxlength="2047" placeholder="Search CIA.gov..."/>
				  <input type="hidden" name="site" value="CIA" />
				  <input type="hidden" name="output" value="xml_no_dtd" />
				  <input type="hidden" name="client" value="CIA" />
				  <input type="hidden" name="myAction" value="/search" />
				  <input type="hidden" name="proxystylesheet" value="CIA" />
				  <input type="hidden" name="submitMethod" value="get" />
                  <input type="submit" value="Search" class="submit" />
                </fieldset>
              </form>

عربي

中文

English

Français

Русский

Español

More Languages

Navigation

              Home

              About CIA

Today's CIA

Leadership

CIA Vision, Mission & Values

Tour Headquarters

CIA Museum

History of the CIA

FAQs

NoFEAR Act

Site Policies

About CIA

Discover the CIA history, mission, vision and values.

              Careers & Internships

  Career Opportunities

  Student Opportunities

  Application Process

  Life at CIA

  Diversity

  Military Transition

  Diversions & Information

  FAQs

Careers & Internships

Your talent. Your diverse skills. Our mission. Learn more about Careers Opportunities at CIA.

              Offices of CIA

  Intelligence & Analysis

  Clandestine Service

  Science & Technology

  Support to Mission

  Human Resources

  Public Affairs

  General Counsel

  Equal Employment Opportunity

  Congressional Affairs

  Inspector General

  Military Affairs

Offices of CIA

Learn how the CIA is organized into directorates and key offices, responsible for securing our nation.

              News & Information

  Press Releases & Statements

  Speeches & Testimony

  CIA & the War on Terrorism

  Featured Story Archive

  What’s New Archive

  Your News

News & Information

The most up-to-date CIA news, press releases, information and more.

              Library

  Publications

  Center for the Study of Intelligence

  Freedom of Information Act Electronic Reading Room

  Kent Center Occasional Papers

  Intelligence Literature

  Reports

  Related Links

  Video Center

Library

Our open-source library houses the thousands of documents, periodicals, maps and reports released to the public.

              Kids' Zone

  K-5th Grade

  6-12th Grade

  Parents & Teachers

  Games

  Related Links

  Privacy Statement

Kids' Zone

Learn more about the Agency – and find some top secret things you won't see anywhere else.

Library

Secondary Navigation

Library

                     Publications

The World Factbook

World Leaders

CIA Maps

Historical Collection Publications

Additional Publications

Center for the Study of Intelligence

Freedom of Information Act Electronic Reading Room

Kent Center Occasional Papers

Intelligence Literature: Suggested Reading List

Reports

Video Center

Related Links

Home

Library

Publications

The World Factbook

                      <form action="#" method="GET">
                         <select name="selecter_links" class="selecter_links" onchange="document.location.href= this.value;">
                             <option value="">Please select a country to view</option>
                                <option value="/library/publications/the-world-factbook/geos/xx.html"> World </option>
                                <option value="/library/publications/the-world-factbook/geos/af.html"> Afghanistan </option>
                                <option value="/library/publications/the-world-factbook/geos/ax.html"> Akrotiri </option>
                                <option value="/library/publications/the-world-factbook/geos/al.html"> Albania </option>
                                <option value="/library/publications/the-world-factbook/geos/ag.html"> Algeria </option>
                                <option value="/library/publications/the-world-factbook/geos/aq.html"> American Samoa </option>
                                <option value="/library/publications/the-world-factbook/geos/an.html"> Andorra </option>
                                <option value="/library/publications/the-world-factbook/geos/ao.html"> Angola </option>
                                <option value="/library/publications/the-world-factbook/geos/av.html"> Anguilla </option>
                                <option value="/library/publications/the-world-factbook/geos/ay.html"> Antarctica </option>
                                <option value="/library/publications/the-world-factbook/geos/ac.html"> Antigua and Barbuda </option>
                                <option value="/library/publications/the-world-factbook/geos/xq.html"> Arctic Ocean </option>
                                <option value="/library/publications/the-world-factbook/south-america/ar.html"> Argentina </option>
                                <option value="/library/publications/the-world-factbook/geos/am.html"> Armenia </option>
                                <option value="/library/publications/the-world-factbook/geos/aa.html"> Aruba </option>
                                <option value="/library/publications/the-world-factbook/geos/at.html"> Ashmore and Cartier Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/zh.html"> Atlantic Ocean </option>
                                <option value="/library/publications/the-world-factbook/geos/as.html"> Australia </option>
                                <option value="/library/publications/the-world-factbook/geos/au.html"> Austria </option>
                                <option value="/library/publications/the-world-factbook/geos/aj.html"> Azerbaijan </option>
                                <option value="/library/publications/the-world-factbook/geos/bf.html"> Bahamas, The </option>
                                <option value="/library/publications/the-world-factbook/geos/ba.html"> Bahrain </option>
                                <option value="/library/publications/the-world-factbook/geos/um.html"> Baker Island </option>
                                <option value="/library/publications/the-world-factbook/geos/bg.html"> Bangladesh </option>
                                <option value="/library/publications/the-world-factbook/geos/bb.html"> Barbados </option>
                                <option value="/library/publications/the-world-factbook/geos/bo.html"> Belarus </option>
                                <option value="/library/publications/the-world-factbook/geos/be.html"> Belgium </option>
                                <option value="/library/publications/the-world-factbook/geos/bh.html"> Belize </option>
                                <option value="/library/publications/the-world-factbook/geos/bn.html"> Benin </option>
                                <option value="/library/publications/the-world-factbook/geos/bd.html"> Bermuda </option>
                                <option value="/library/publications/the-world-factbook/geos/bt.html"> Bhutan </option>
                                <option value="/library/publications/the-world-factbook/south-america/bl.html"> Bolivia </option>
                                <option value="/library/publications/the-world-factbook/geos/bk.html"> Bosnia and Herzegovina </option>
                                <option value="/library/publications/the-world-factbook/geos/bc.html"> Botswana </option>
                                <option value="/library/publications/the-world-factbook/geos/bv.html"> Bouvet Island </option>
                                <option value="/library/publications/the-world-factbook/south-america/br.html"> Brazil </option>
                                <option value="/library/publications/the-world-factbook/geos/io.html"> British Indian Ocean Territory </option>
                                <option value="/library/publications/the-world-factbook/geos/vi.html"> British Virgin Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/bx.html"> Brunei </option>
                                <option value="/library/publications/the-world-factbook/geos/bu.html"> Bulgaria </option>
                                <option value="/library/publications/the-world-factbook/geos/uv.html"> Burkina Faso </option>
                                <option value="/library/publications/the-world-factbook/geos/bm.html"> Burma </option>
                                <option value="/library/publications/the-world-factbook/geos/by.html"> Burundi </option>
                                <option value="/library/publications/the-world-factbook/geos/cv.html"> Cabo Verde </option>
                                <option value="/library/publications/the-world-factbook/geos/cb.html"> Cambodia </option>
                                <option value="/library/publications/the-world-factbook/geos/cm.html"> Cameroon </option>
                                <option value="/library/publications/the-world-factbook/geos/ca.html"> Canada </option>
                                <option value="/library/publications/the-world-factbook/geos/cj.html"> Cayman Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/ct.html"> Central African Republic </option>
                                <option value="/library/publications/the-world-factbook/geos/cd.html"> Chad </option>
                                <option value="/library/publications/the-world-factbook/south-america/ci.html"> Chile </option>
                                <option value="/library/publications/the-world-factbook/geos/ch.html"> China </option>
                                <option value="/library/publications/the-world-factbook/geos/kt.html"> Christmas Island </option>
                                <option value="/library/publications/the-world-factbook/geos/ip.html"> Clipperton Island </option>
                                <option value="/library/publications/the-world-factbook/geos/ck.html"> Cocos (Keeling) Islands </option>
                                <option value="/library/publications/the-world-factbook/south-america/co.html"> Colombia </option>
                                <option value="/library/publications/the-world-factbook/geos/cn.html"> Comoros </option>
                                <option value="/library/publications/the-world-factbook/geos/cg.html"> Congo, Democratic Republic of the </option>
                                <option value="/library/publications/the-world-factbook/geos/cf.html"> Congo, Republic of the </option>
                                <option value="/library/publications/the-world-factbook/geos/cw.html"> Cook Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/cr.html"> Coral Sea Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/cs.html"> Costa Rica </option>
                                <option value="/library/publications/the-world-factbook/geos/iv.html"> Cote d'Ivoire </option>
                                <option value="/library/publications/the-world-factbook/geos/hr.html"> Croatia </option>
                                <option value="/library/publications/the-world-factbook/geos/cu.html"> Cuba </option>
                                <option value="/library/publications/the-world-factbook/geos/cc.html"> Curacao </option>
                                <option value="/library/publications/the-world-factbook/geos/cy.html"> Cyprus </option>
                                <option value="/library/publications/the-world-factbook/geos/ez.html"> Czech Republic </option>
                                <option value="/library/publications/the-world-factbook/geos/da.html"> Denmark </option>
                                <option value="/library/publications/the-world-factbook/geos/dx.html"> Dhekelia </option>
                                <option value="/library/publications/the-world-factbook/geos/dj.html"> Djibouti </option>
                                <option value="/library/publications/the-world-factbook/geos/do.html"> Dominica </option>
                                <option value="/library/publications/the-world-factbook/geos/dr.html"> Dominican Republic </option>
                                <option value="/library/publications/the-world-factbook/south-america/ec.html"> Ecuador </option>
                                <option value="/library/publications/the-world-factbook/geos/eg.html"> Egypt </option>
                                <option value="/library/publications/the-world-factbook/geos/es.html"> El Salvador </option>
                                <option value="/library/publications/the-world-factbook/geos/ek.html"> Equatorial Guinea </option>
                                <option value="/library/publications/the-world-factbook/geos/er.html"> Eritrea </option>
                                <option value="/library/publications/the-world-factbook/geos/en.html"> Estonia </option>
                                <option value="/library/publications/the-world-factbook/geos/et.html"> Ethiopia </option>
                                <option value="/library/publications/the-world-factbook/south-america/fk.html"> Falkland Islands (Islas Malvinas) </option>
                                <option value="/library/publications/the-world-factbook/geos/fo.html"> Faroe Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/fj.html"> Fiji </option>
                                <option value="/library/publications/the-world-factbook/geos/fi.html"> Finland </option>
                                <option value="/library/publications/the-world-factbook/geos/fr.html"> France </option>
                                <option value="/library/publications/the-world-factbook/geos/fp.html"> French Polynesia </option>
                                <option value="/library/publications/the-world-factbook/geos/fs.html"> French Southern and Antarctic Lands </option>
                                <option value="/library/publications/the-world-factbook/geos/gb.html"> Gabon </option>
                                <option value="/library/publications/the-world-factbook/geos/ga.html"> Gambia, The </option>
                                <option value="/library/publications/the-world-factbook/geos/gz.html"> Gaza Strip </option>
                                <option value="/library/publications/the-world-factbook/geos/gg.html"> Georgia </option>
                                <option value="/library/publications/the-world-factbook/geos/gm.html"> Germany </option>
                                <option value="/library/publications/the-world-factbook/geos/gh.html"> Ghana </option>
                                <option value="/library/publications/the-world-factbook/geos/gi.html"> Gibraltar </option>
                                <option value="/library/publications/the-world-factbook/geos/gr.html"> Greece </option>
                                <option value="/library/publications/the-world-factbook/geos/gl.html"> Greenland </option>
                                <option value="/library/publications/the-world-factbook/geos/gj.html"> Grenada </option>
                                <option value="/library/publications/the-world-factbook/geos/gq.html"> Guam </option>
                                <option value="/library/publications/the-world-factbook/geos/gt.html"> Guatemala </option>
                                <option value="/library/publications/the-world-factbook/geos/gk.html"> Guernsey </option>
                                <option value="/library/publications/the-world-factbook/geos/gv.html"> Guinea </option>
                                <option value="/library/publications/the-world-factbook/geos/pu.html"> Guinea-Bissau </option>
                                <option value="/library/publications/the-world-factbook/south-america/gy.html"> Guyana </option>
                                <option value="/library/publications/the-world-factbook/geos/ha.html"> Haiti </option>
                                <option value="/library/publications/the-world-factbook/geos/hm.html"> Heard Island and McDonald Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/vt.html"> Holy See (Vatican City) </option>
                                <option value="/library/publications/the-world-factbook/geos/ho.html"> Honduras </option>
                                <option value="/library/publications/the-world-factbook/geos/hk.html"> Hong Kong </option>
                                <option value="/library/publications/the-world-factbook/geos/um.html"> Howland Island </option>
                                <option value="/library/publications/the-world-factbook/geos/hu.html"> Hungary </option>
                                <option value="/library/publications/the-world-factbook/geos/ic.html"> Iceland </option>
                                <option value="/library/publications/the-world-factbook/geos/in.html"> India </option>
                                <option value="/library/publications/the-world-factbook/geos/xo.html"> Indian Ocean </option>
                                <option value="/library/publications/the-world-factbook/geos/id.html"> Indonesia </option>
                                <option value="/library/publications/the-world-factbook/geos/ir.html"> Iran </option>
                                <option value="/library/publications/the-world-factbook/geos/iz.html"> Iraq </option>
                                <option value="/library/publications/the-world-factbook/geos/ei.html"> Ireland </option>
                                <option value="/library/publications/the-world-factbook/geos/im.html"> Isle of Man </option>
                                <option value="/library/publications/the-world-factbook/geos/is.html"> Israel </option>
                                <option value="/library/publications/the-world-factbook/geos/it.html"> Italy </option>
                                <option value="/library/publications/the-world-factbook/geos/jm.html"> Jamaica </option>
                                <option value="/library/publications/the-world-factbook/geos/jn.html"> Jan Mayen </option>
                                <option value="/library/publications/the-world-factbook/geos/ja.html"> Japan </option>
                                <option value="/library/publications/the-world-factbook/geos/um.html"> Jarvis Island </option>
                                <option value="/library/publications/the-world-factbook/geos/je.html"> Jersey </option>
                                <option value="/library/publications/the-world-factbook/geos/um.html"> Johnston Atoll </option>
                                <option value="/library/publications/the-world-factbook/geos/jo.html"> Jordan </option>
                                <option value="/library/publications/the-world-factbook/geos/kz.html"> Kazakhstan </option>
                                <option value="/library/publications/the-world-factbook/geos/ke.html"> Kenya </option>
                                <option value="/library/publications/the-world-factbook/geos/um.html"> Kingman Reef </option>
                                <option value="/library/publications/the-world-factbook/geos/kr.html"> Kiribati </option>
                                <option value="/library/publications/the-world-factbook/geos/kn.html"> Korea, North </option>
                                <option value="/library/publications/the-world-factbook/geos/ks.html"> Korea, South </option>
                                <option value="/library/publications/the-world-factbook/geos/kv.html"> Kosovo </option>
                                <option value="/library/publications/the-world-factbook/geos/ku.html"> Kuwait </option>
                                <option value="/library/publications/the-world-factbook/geos/kg.html"> Kyrgyzstan </option>
                                <option value="/library/publications/the-world-factbook/geos/la.html"> Laos </option>
                                <option value="/library/publications/the-world-factbook/geos/lg.html"> Latvia </option>
                                <option value="/library/publications/the-world-factbook/geos/le.html"> Lebanon </option>
                                <option value="/library/publications/the-world-factbook/geos/lt.html"> Lesotho </option>
                                <option value="/library/publications/the-world-factbook/geos/li.html"> Liberia </option>
                                <option value="/library/publications/the-world-factbook/geos/ly.html"> Libya </option>
                                <option value="/library/publications/the-world-factbook/geos/ls.html"> Liechtenstein </option>
                                <option value="/library/publications/the-world-factbook/geos/lh.html"> Lithuania </option>
                                <option value="/library/publications/the-world-factbook/geos/lu.html"> Luxembourg </option>
                                <option value="/library/publications/the-world-factbook/geos/mc.html"> Macau </option>
                                <option value="/library/publications/the-world-factbook/geos/mk.html"> Macedonia </option>
                                <option value="/library/publications/the-world-factbook/geos/ma.html"> Madagascar </option>
                                <option value="/library/publications/the-world-factbook/geos/mi.html"> Malawi </option>
                                <option value="/library/publications/the-world-factbook/geos/my.html"> Malaysia </option>
                                <option value="/library/publications/the-world-factbook/geos/mv.html"> Maldives </option>
                                <option value="/library/publications/the-world-factbook/geos/ml.html"> Mali </option>
                                <option value="/library/publications/the-world-factbook/geos/mt.html"> Malta </option>
                                <option value="/library/publications/the-world-factbook/geos/rm.html"> Marshall Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/mr.html"> Mauritania </option>
                                <option value="/library/publications/the-world-factbook/geos/mp.html"> Mauritius </option>
                                <option value="/library/publications/the-world-factbook/geos/mx.html"> Mexico </option>
                                <option value="/library/publications/the-world-factbook/geos/fm.html"> Micronesia, Federated States of </option>
                                <option value="/library/publications/the-world-factbook/geos/um.html"> Midway Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/md.html"> Moldova </option>
                                <option value="/library/publications/the-world-factbook/geos/mn.html"> Monaco </option>
                                <option value="/library/publications/the-world-factbook/geos/mg.html"> Mongolia </option>
                                <option value="/library/publications/the-world-factbook/geos/mj.html"> Montenegro </option>
                                <option value="/library/publications/the-world-factbook/geos/mh.html"> Montserrat </option>
                                <option value="/library/publications/the-world-factbook/geos/mo.html"> Morocco </option>
                                <option value="/library/publications/the-world-factbook/geos/mz.html"> Mozambique </option>
                                <option value="/library/publications/the-world-factbook/geos/wa.html"> Namibia </option>
                                <option value="/library/publications/the-world-factbook/geos/nr.html"> Nauru </option>
                                <option value="/library/publications/the-world-factbook/geos/bq.html"> Navassa Island </option>
                                <option value="/library/publications/the-world-factbook/geos/np.html"> Nepal </option>
                                <option value="/library/publications/the-world-factbook/geos/nl.html"> Netherlands </option>
                                <option value="/library/publications/the-world-factbook/geos/nc.html"> New Caledonia </option>
                                <option value="/library/publications/the-world-factbook/geos/nz.html"> New Zealand </option>
                                <option value="/library/publications/the-world-factbook/geos/nu.html"> Nicaragua </option>
                                <option value="/library/publications/the-world-factbook/geos/ng.html"> Niger </option>
                                <option value="/library/publications/the-world-factbook/geos/ni.html"> Nigeria </option>
                                <option value="/library/publications/the-world-factbook/geos/ne.html"> Niue </option>
                                <option value="/library/publications/the-world-factbook/geos/nf.html"> Norfolk Island </option>
                                <option value="/library/publications/the-world-factbook/geos/cq.html"> Northern Mariana Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/no.html"> Norway </option>
                                <option value="/library/publications/the-world-factbook/geos/mu.html"> Oman </option>
                                <option value="/library/publications/the-world-factbook/geos/zn.html"> Pacific Ocean </option>
                                <option value="/library/publications/the-world-factbook/geos/pk.html"> Pakistan </option>
                                <option value="/library/publications/the-world-factbook/geos/ps.html"> Palau </option>
                                <option value="/library/publications/the-world-factbook/geos/um.html"> Palmyra Atoll </option>
                                <option value="/library/publications/the-world-factbook/geos/pm.html"> Panama </option>
                                <option value="/library/publications/the-world-factbook/geos/pp.html"> Papua New Guinea </option>
                                <option value="/library/publications/the-world-factbook/geos/pf.html"> Paracel Islands </option>
                                <option value="/library/publications/the-world-factbook/south-america/pa.html"> Paraguay </option>
                                <option value="/library/publications/the-world-factbook/south-america/pe.html"> Peru </option>
                                <option value="/library/publications/the-world-factbook/geos/rp.html"> Philippines </option>
                                <option value="/library/publications/the-world-factbook/geos/pc.html"> Pitcairn Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/pl.html"> Poland </option>
                                <option value="/library/publications/the-world-factbook/geos/po.html"> Portugal </option>
                                <option value="/library/publications/the-world-factbook/geos/rq.html"> Puerto Rico </option>
                                <option value="/library/publications/the-world-factbook/geos/qa.html"> Qatar </option>
                                <option value="/library/publications/the-world-factbook/geos/ro.html"> Romania </option>
                                <option value="/library/publications/the-world-factbook/geos/rs.html"> Russia </option>
                                <option value="/library/publications/the-world-factbook/geos/rw.html"> Rwanda </option>
                                <option value="/library/publications/the-world-factbook/geos/tb.html"> Saint Barthelemy </option>
                                <option value="/library/publications/the-world-factbook/geos/sh.html"> Saint Helena, Ascension, and Tristan da Cunha </option>
                                <option value="/library/publications/the-world-factbook/geos/sc.html"> Saint Kitts and Nevis </option>
                                <option value="/library/publications/the-world-factbook/geos/st.html"> Saint Lucia </option>
                                <option value="/library/publications/the-world-factbook/geos/rn.html"> Saint Martin </option>
                                <option value="/library/publications/the-world-factbook/geos/sb.html"> Saint Pierre and Miquelon </option>
                                <option value="/library/publications/the-world-factbook/geos/vc.html"> Saint Vincent and the Grenadines </option>
                                <option value="/library/publications/the-world-factbook/geos/ws.html"> Samoa </option>
                                <option value="/library/publications/the-world-factbook/geos/sm.html"> San Marino </option>
                                <option value="/library/publications/the-world-factbook/geos/tp.html"> Sao Tome and Principe </option>
                                <option value="/library/publications/the-world-factbook/geos/sa.html"> Saudi Arabia </option>
                                <option value="/library/publications/the-world-factbook/geos/sg.html"> Senegal </option>
                                <option value="/library/publications/the-world-factbook/geos/ri.html"> Serbia </option>
                                <option value="/library/publications/the-world-factbook/geos/se.html"> Seychelles </option>
                                <option value="/library/publications/the-world-factbook/geos/sl.html"> Sierra Leone </option>
                                <option value="/library/publications/the-world-factbook/geos/sn.html"> Singapore </option>
                                <option value="/library/publications/the-world-factbook/geos/sk.html"> Sint Maarten </option>
                                <option value="/library/publications/the-world-factbook/geos/lo.html"> Slovakia </option>
                                <option value="/library/publications/the-world-factbook/geos/si.html"> Slovenia </option>
                                <option value="/library/publications/the-world-factbook/geos/bp.html"> Solomon Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/so.html"> Somalia </option>
                                <option value="/library/publications/the-world-factbook/geos/sf.html"> South Africa </option>
                                <option value="/library/publications/the-world-factbook/geos/oo.html"> Southern Ocean </option>
                                <option value="/library/publications/the-world-factbook/south-america/sx.html"> South Georgia and South Sandwich Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/od.html"> South Sudan </option>
                                <option value="/library/publications/the-world-factbook/geos/sp.html"> Spain </option>
                                <option value="/library/publications/the-world-factbook/geos/pg.html"> Spratly Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/ce.html"> Sri Lanka </option>
                                <option value="/library/publications/the-world-factbook/geos/su.html"> Sudan </option>
                                <option value="/library/publications/the-world-factbook/south-america/ns.html"> Suriname </option>
                                <option value="/library/publications/the-world-factbook/geos/sv.html"> Svalbard </option>
                                <option value="/library/publications/the-world-factbook/geos/wz.html"> Swaziland </option>
                                <option value="/library/publications/the-world-factbook/geos/sw.html"> Sweden </option>
                                <option value="/library/publications/the-world-factbook/geos/sz.html"> Switzerland </option>
                                <option value="/library/publications/the-world-factbook/geos/sy.html"> Syria </option>
                                <option value="/library/publications/the-world-factbook/geos/tw.html"> Taiwan </option>
                                <option value="/library/publications/the-world-factbook/geos/ti.html"> Tajikistan </option>
                                <option value="/library/publications/the-world-factbook/geos/tz.html"> Tanzania </option>
                                <option value="/library/publications/the-world-factbook/geos/th.html"> Thailand </option>
                                <option value="/library/publications/the-world-factbook/geos/tt.html"> Timor-Leste </option>
                                <option value="/library/publications/the-world-factbook/geos/to.html"> Togo </option>
                                <option value="/library/publications/the-world-factbook/geos/tl.html"> Tokelau </option>
                                <option value="/library/publications/the-world-factbook/geos/tn.html"> Tonga </option>
                                <option value="/library/publications/the-world-factbook/geos/td.html"> Trinidad and Tobago </option>
                                <option value="/library/publications/the-world-factbook/geos/ts.html"> Tunisia </option>
                                <option value="/library/publications/the-world-factbook/geos/tu.html"> Turkey </option>
                                <option value="/library/publications/the-world-factbook/geos/tx.html"> Turkmenistan </option>
                                <option value="/library/publications/the-world-factbook/geos/tk.html"> Turks and Caicos Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/tv.html"> Tuvalu </option>
                                <option value="/library/publications/the-world-factbook/geos/ug.html"> Uganda </option>
                                <option value="/library/publications/the-world-factbook/geos/up.html"> Ukraine </option>
                                <option value="/library/publications/the-world-factbook/geos/ae.html"> United Arab Emirates </option>
                                <option value="/library/publications/the-world-factbook/geos/uk.html"> United Kingdom </option>
                                <option value="/library/publications/the-world-factbook/geos/us.html"> United States </option>
                                <option value="/library/publications/the-world-factbook/geos/um.html"> United States Pacific Island Wildlife Refuges </option>
                                <option value="/library/publications/the-world-factbook/south-america/uy.html"> Uruguay </option>
                                <option value="/library/publications/the-world-factbook/geos/uz.html"> Uzbekistan </option>
                                <option value="/library/publications/the-world-factbook/geos/nh.html"> Vanuatu </option>
                                <option value="/library/publications/the-world-factbook/south-america/ve.html"> Venezuela </option>
                                <option value="/library/publications/the-world-factbook/geos/vm.html"> Vietnam </option>
                                <option value="/library/publications/the-world-factbook/geos/vq.html"> Virgin Islands </option>
                                <option value="/library/publications/the-world-factbook/geos/wq.html"> Wake Island </option>
                                <option value="/library/publications/the-world-factbook/geos/wf.html"> Wallis and Futuna </option>
                                <option value="/library/publications/the-world-factbook/geos/we.html"> West Bank </option>
                                <option value="/library/publications/the-world-factbook/geos/wi.html"> Western Sahara </option>
                                <option value="/library/publications/the-world-factbook/geos/ym.html"> Yemen </option>
                                <option value="/library/publications/the-world-factbook/geos/za.html"> Zambia </option>
                                <option value="/library/publications/the-world-factbook/geos/zi.html"> Zimbabwe </option>
                                <option value="/library/publications/the-world-factbook/geos/ee.html"> European Union </option>
                             </select>
                          </form>

ABOUT

History

Copyright and Contributors

Purchasing

Did You Know?

REFERENCES

Regional and World Maps

Flags of the World

Gallery of Covers

Definitions and Notes

Guide to Country Profiles

Guide to Country Comparisons

The World Factbook Users Guide

APPENDICES

A: abbreviations

B: international organizations and groups

C: selected international environmental agreements

D: cross-reference list of country data codes

E: cross-reference list of hydrographic data codes

F: cross-reference list of geographic names

G: weights and measures

FAQs

  CONTACT

FIELD LISTING :: LANGUAGES

This entry provides a rank ordering of languages starting with the largest and sometimes includes the percent of total population speaking that language.

Country Comparison to the World

Country	LANGUAGES(%)

Afghanistan
Afghan Persian or Dari (official) 50%, Pashto (official) 35%, Turkic languages (primarily Uzbek and Turkmen) 11%, 30 minor languages (primarily Balochi and Pashai) 4%, much bilingualism, but Dari functions as the lingua franca

note: the Turkic languages Uzbek and Turkmen, as well as Balochi, Pashai, Nuristani, and Pamiri are the third official languages in areas where the majority speaks them

Akrotiri
English, Greek

Albania
Albanian 98.8% (official - derived from Tosk dialect), Greek 0.5%, other 0.6% (including Macedonian, Roma, Vlach, Turkish, Italian, and Serbo-Croatian), unspecified 0.1% (2011 est.)

Algeria
Arabic (official), French (lingua franca), Berber dialects: Kabylie Berber (Tamazight), Chaouia Berber (Tachawit), Mzab Berber, Tuareg Berber (Tamahaq)

American Samoa
Samoan 88.6% (closely related to Hawaiian and other Polynesian languages), English 3.9%, Tongan 2.7%, other Pacific islander 3%, other 1.8%

note: most people are bilingual (2010 est.)

Andorra
Catalan (official), French, Castilian, Portuguese

Angola
Portuguese (official), Bantu and other African languages

Anguilla
English (official)

Antigua and Barbuda
English (official), Antiguan creole

Argentina
Spanish (official), Italian, English, German, French, indigenous (Mapudungun, Quechua)

Armenia
Armenian (official) 97.9%, Kurdish (spoken by Yezidi minority) 1%, other 1% (2011 est.)

Aruba
Papiamento (a Spanish-Portuguese-Dutch-English dialect) 69.4%, Spanish 13.7%, English (widely spoken) 7.1%, Dutch (official) 6.1%, Chinese 1.5%, other 1.7%, unspecified 0.4% (2010 est.)

Australia
English 76.8%, Mandarin 1.6%, Italian 1.4%, Arabic 1.3%, Greek 1.2%, Cantonese 1.2%, Vietnamese 1.1%, other 10.4%, unspecified 5% (2011 est.)

Austria
German (official nationwide) 88.6%, Turkish 2.3%, Serbian 2.2%, Croatian (official in Burgenland) 1.6%, other (includes Slovene, official in South Carinthia, and Hungarian, official in Burgenland) 5.3% (2001 est.)

Azerbaijan
Azerbaijani (Azeri) (official) 92.5%, Russian 1.4%, Armenian 1.4%, other 4.7% (2009 est.)

Bahamas, The
English (official), Creole (among Haitian immigrants)

Bahrain
Arabic (official), English, Farsi, Urdu

Bangladesh
Bangla 98.8% (official, also known as Bengali), other 1.2% (2011 est.)

Barbados
English (official), Bajan (English-based creole language, widely spoken in informal settings)

Belarus
Belarusian (official) 23.4%, Russian (official) 70.2%, other 3.1% (includes small Polish- and Ukrainian-speaking minorities), unspecified 3.3% (2009 est.)

Belgium
Dutch (official) 60%, French (official) 40%, German (official) less than 1%

Belize
English 62.9% (official), Spanish 56.6%, Creole 44.6%, Maya 10.5%, German 3.2%, Garifuna 2.9%, other 1.8%, unknown 0.3%, none 0.2% (cannot speak)

note: shares sum to more than 100% because some respondents gave more than one answer on the census (2010 est.)

Benin
French (official), Fon and Yoruba (most common vernaculars in south), tribal languages (at least six major ones in north)

Bermuda
English (official), Portuguese

Bhutan
Sharchhopka 28%, Dzongkha (official) 24%, Lhotshamkha 22%, other 26% (includes foreign languages) (2005 est.)

Bolivia
Spanish (official) 60.7%, Quechua (official) 21.2%, Aymara (official) 14.6%, foreign languages 2.4%, Guarani (official) 0.6%, other native languages 0.4%, none 0.1%

note: Bolivia's 2009 constitution designates Spanish and all indigenous languages as official; 36 indigenous languages are specified, including some that are extinct (2001 est.)

Bosnia and Herzegovina
Bosnian (official), Croatian (official), Serbian (official)

Botswana
Setswana 78.2%, Kalanga 7.9%, Sekgalagadi 2.8%, English (official) 2.1%, Sesarwa 1.9%, Sempukushu 1.7%, other 5.1%, unspecified 0.2% (2001 est.)

Brazil
Portuguese (official and most widely spoken language)

note: less common languages include Spanish (border areas and schools), German, Italian, Japanese, English, and a large number of minor Amerindian languages

British Virgin Islands
English (official)

Brunei
Malay (official), English, Chinese dialects

Bulgaria
Bulgarian (official) 76.8%, Turkish 8.2%, Roma 3.8%, other 0.7%, unspecified 10.5% (2011 est.)

Burkina Faso
French (official), native African languages belonging to Sudanic family spoken by 90% of the population

Burma
Burmese (official)

note: minority ethnic groups have their own languages

Burundi
Kirundi 29.7% (official), Kirundi and other language 9.1%, French (official) and French and other language 0.3%, Swahili and Swahili and other language 0.2% (along Lake Tanganyika and in the Bujumbura area), English and English and other language 0.06%, more than 2 languages 3.7%, unspecified 56.9% (2008 est.)

Cabo Verde
Portuguese (official), Crioulo (a blend of Portuguese and West African words)

Cambodia
Khmer (official) 96.3%, other 3.7% (2008 est.)

Cameroon
24 major African language groups, English (official), French (official)

Canada
English (official) 58.7%, French (official) 22%, Punjabi 1.4%, Italian 1.3%, Spanish 1.3%, German 1.3%, Cantonese 1.2%, Tagalog 1.2%, Arabic 1.1%, other 10.5% (2011 est.)

Cayman Islands
English (official) 90.9%, Spanish 4%, Filipino 3.3%, other 1.7%, unspecified 0.1% (2010 est.)

Central African Republic
French (official), Sangho (lingua franca and national language), tribal languages

Chad
French (official), Arabic (official), Sara (in south), more than 120 different languages and dialects

Chile
Spanish 99.5% (official), English 10.2%, indigenous 1% (includes Mapudungun, Aymara, Quechua, Rapa Nui), other 2.3%, unspecified 0.2%

note: shares sum to more than 100% because some respondents gave more than one answer on the census (2012 est.)

China
Standard Chinese or Mandarin (official; Putonghua, based on the Beijing dialect), Yue (Cantonese), Wu (Shanghainese), Minbei (Fuzhou), Minnan (Hokkien-Taiwanese), Xiang, Gan, Hakka dialects, minority languages (see Ethnic groups entry)

note: Zhuang is official in Guangxi Zhuang, Yue is official in Guangdong, Mongolian is official in Nei Mongol, Uighur is official in Xinjiang Uygur, Kyrgyz is official in Xinjiang Uyghur, and Tibetan is official in Xizang (Tibet)

Christmas Island
English (official), Chinese, Malay

Cocos (Keeling) Islands
Malay (Cocos dialect), English

Colombia
Spanish (official)

Comoros
Arabic (official), French (official), Shikomoro (official; a blend of Swahili and Arabic) (Comorian)

Congo, Democratic Republic of the
French (official), Lingala (a lingua franca trade language), Kingwana (a dialect of Kiswahili or Swahili), Kikongo, Tshiluba

Congo, Republic of the
French (official), Lingala and Monokutuba (lingua franca trade languages), many local languages and dialects (of which Kikongo is the most widespread)

Cook Islands
English (official) 86.4%, Cook Islands Maori (Rarotongan) (official) 76.2%, other 8.3%

note: shares sum to more than 100% because some respondents gave more than one answer on the census (2011 est.)

Costa Rica
Spanish (official), English

Cote d'Ivoire
French (official), 60 native dialects of which Dioula is the most widely spoken

Croatia
Croatian (official) 95.6%, Serbian 1.2%, other 3% (including Hungarian, Czech, Slovak, and Albanian), unspecified 0.2% (2011 est.)

Cuba
Spanish (official)

Curacao
Papiamentu (a Spanish-Portuguese-Dutch-English dialect) 81.2%, Dutch (official) 8%, Spanish 4%, English 2.9%, other 3.9% (2001 census)

Cyprus
Greek (official) 80.9%, Turkish (official) 0.2%, English 4.1%, Romanian 2.9%, Russian 2.5%, Bulgarian 2.2%, Arabic 1.2%, Filippino 1.1%, other 4.3%, unspecified 0.6% (2011 est.)

Czech Republic
Czech (official) 95.4%, Slovak 1.6%, other 3% (2011 census)

Denmark
Danish, Faroese, Greenlandic (an Inuit dialect), German (small minority)

note: English is the predominant second language

Dhekelia
English, Greek

Djibouti
French (official), Arabic (official), Somali, Afar

Dominica
English (official), French patois

Dominican Republic
Spanish (official)

Ecuador
Spanish (Castillian) 93% (official), Quechua 4.1%, other indigenous 0.7%, foreign 2.2%

note: (Quechua and Shuar are official languages of intercultural relations; other indigenous languages are in official use by indigenous peoples in the areas they inhabit) (2010 est.)

Egypt
Arabic (official), English and French widely understood by educated classes

El Salvador
Spanish (official), Nahua (among some Amerindians)

Equatorial Guinea
Spanish (official) 67.6%, other (includes French (official), Fang, Bubi) 32.4% (1994 census)

Eritrea
Tigrinya (official), Arabic (official), English (official), Tigre, Kunama, Afar, other Cushitic languages

Estonia
Estonian (official) 68.5%, Russian 29.6%, Ukrainian 0.6%, other 1.2%, unspecified 0.1% (2011 est.)

Ethiopia
Oromo (official working language in the State of Oromiya) 33.8%, Amharic (official national language) 29.3%, Somali (official working language of the State of Sumale) 6.2%, Tigrigna (Tigrinya) (official working language of the State of Tigray) 5.9%, Sidamo 4%, Wolaytta 2.2%, Gurage 2%, Afar (official working language of the State of Afar) 1.7%, Hadiyya 1.7%, Gamo 1.5%, Gedeo 1.3%, Opuuo 1.2%, Kafa 1.1%, other 8.1%, English (major foreign language taught in schools), Arabic (2007 est.)

European Union
Bulgarian, Croatian, Czech, Danish, Dutch, English, Estonian, Finnish, French, Gaelic, German, Greek, Hungarian, Italian, Latvian, Lithuanian, Maltese, Polish, Portuguese, Romanian, Slovak, Slovene, Spanish, Swedish

note: only the 24 official languages are listed; German, the major language of Germany, Austria, and Switzerland, is the most widely spoken mother tongue - about 18% of the EU population; English is the most widely spoken foreign language - about 38% of the EU population is conversant with it (2013)

Falkland Islands (Islas Malvinas)
English 89%, Spanish 7.7%, other 3.3% (2006 est.)

Faroe Islands
Faroese (derived from Old Norse), Danish

Fiji
English (official), Fijian (official), Hindustani

Finland
Finnish (official) 89.3%, Swedish (official) 5.3%, other (includes small Sami- and Russian-speaking minorities) 5.4% (2013 est.)

France
French (official) 100%, rapidly declining regional dialects and languages (Provencal, Breton, Alsatian, Corsican, Catalan, Basque, Flemish)

overseas departments: French, Creole patois, Mahorian (a Swahili dialect)

French Polynesia
French (official) 61.1%, Polynesian (official) 31.4%, Asian languages 1.2%, other 0.3%, unspecified 6% (2002 census)

Gabon
French (official), Fang, Myene, Nzebi, Bapounou/Eschira, Bandjabi

Gambia, The
English (official), Mandinka, Wolof, Fula, other indigenous vernaculars

Gaza Strip
Arabic, Hebrew (spoken by many Palestinians), English (widely understood)

Georgia
Georgian (official) 71%, Russian 9%, Armenian 7%, Azeri 6%, other 7%

note: Abkhaz is the official language in Abkhazia

Germany
German (official)

note: Lower Sorbian, North Frisian, Sater Frisian, and Upper Sorbian are recognized as regional languages under the European Charter for Regional or Minority Languages

Ghana
Asante 14.8%, Ewe 12.7%, Fante 9.9%, Boron (Brong) 4.6%, Dagomba 4.3%, Dangme 4.3%, Dagarte (Dagaba) 3.7%, Akyem 3.4%, Ga 3.4%, Akuapem 2.9%, other (includes English (official)) 36.1% (2000 census)

Gibraltar
English (used in schools and for official purposes), Spanish, Italian, Portuguese

Greece
Greek (official) 99%, other (includes English and French) 1%

Greenland
Greenlandic (East Inuit) (official), Danish (official), English

Grenada
English (official), French patois

Guam
English 43.6%, Filipino 21.2%, Chamorro 17.8%, other Pacific island languages 10%, Asian languages 6.3%, other 1.1% (2010 est.)

Guatemala
Spanish (official) 60%, Amerindian languages 40%

note: there are 23 officially recognized Amerindian languages, including Quiche, Cakchiquel, Kekchi, Mam, Garifuna, and Xinca

Guernsey
English, French, Norman-French dialect spoken in country districts

Guinea-Bissau
Portuguese (official), Crioulo, African languages

Guinea
French (official)

note: each ethnic group has its own language

Guyana
English (official), Guyanese Creole, Amerindian languages (including Caribbean and Arawak languages), Indian languages (including Caribbean Hindustani, a dialect of Hindi), Chinese (2014 est.)

Haiti
French (official), Creole (official)

Holy See (Vatican City)
Italian, Latin, French, various other languages

Honduras
Spanish (official), Amerindian dialects

Hong Kong
Cantonese (official) 89.5%, English (official) 3.5%, Putonghua (Mandarin) 1.4%, other Chinese dialects 4%, other 1.6% (2011 est.)

Hungary
Hungarian (official) 99.6%, English 16%, German 11.2%, Russian 1.6%, Romanian 1.3%, French 1.2%, other 4.2%

note: shares sum to more than 100% because some respondents gave more than one answer on the census; Hungarian is the mother tongue of 98.9% of Hungarian speakers (2011 est.)

Iceland
Icelandic, English, Nordic languages, German widely spoken

India
Hindi 41%, Bengali 8.1%, Telugu 7.2%, Marathi 7%, Tamil 5.9%, Urdu 5%, Gujarati 4.5%, Kannada 3.7%, Malayalam 3.2%, Oriya 3.2%, Punjabi 2.8%, Assamese 1.3%, Maithili 1.2%, other 5.9%

note: English enjoys the status of subsidiary official language but is the most important language for national, political, and commercial communication; Hindi is the most widely spoken language and primary tongue of 41% of the people; there are 14 other official languages: Bengali, Telugu, Marathi, Tamil, Urdu, Gujarati, Malayalam, Kannada, Oriya, Punjabi, Assamese, Kashmiri, Sindhi, and Sanskrit; Hindustani is a popular variant of Hindi/Urdu spoken widely throughout northern India but is not an official language (2001 census)

Indonesia
Bahasa Indonesia (official, modified form of Malay), English, Dutch, local dialects (of which the most widely spoken is Javanese)

note: more than 700 languages are used in Indonesia

Iran
Persian (official) 53%, Azeri Turkic and Turkic dialects 18%, Kurdish 10%, Gilaki and Mazandarani 7%, Luri 6%, Balochi 2%, Arabic 2%, other 2%

Iraq
Arabic (official), Kurdish (official), Turkmen (a Turkish dialect) and Assyrian (Neo-Aramaic) are official in areas where they constitute a majority of the population), Armenian

Ireland
English (official, the language generally used), Irish (Gaelic or Gaeilge) (official, spoken by approximately 38.7% of the population as a first or second language in 2011; mainly spoken in areas along the western coast)

Isle of Man
English, Manx Gaelic (about 2% of the population has some knowledge)

Israel
Hebrew (official), Arabic (used officially for Arab minority), English (most commonly used foreign language)

Italy
Italian (official), German (parts of Trentino-Alto Adige region are predominantly German-speaking), French (small French-speaking minority in Valle d'Aosta region), Slovene (Slovene-speaking minority in the Trieste-Gorizia area)

Jamaica
English, English patois

Japan
Japanese

Jersey
English 94.5% (official), Portuguese 4.6%, other 0.9% (2001 census)

Jordan
Arabic (official), English (widely understood among upper and middle classes)

Kazakhstan
Kazakh (official, Qazaq) 64.4%, Russian (official, used in everyday business, designated the "language of interethnic communication") 95% (2001 est.)

Kenya
English (official), Kiswahili (official), numerous indigenous languages

Kiribati
I-Kiribati, English (official)

Korea, North
Korean

Korea, South
Korean, English (widely taught in junior high and high school)

Kosovo
Albanian (official) 94.5%, Bosnian 1.7%, Serbian (official) 1.6%, Turkish 1.1%, other 0.9% (includes Romani), unspecified 0.1%

note: in municipalities where a community's mother tongue is not one of Kosovo's offical languages, the language of that community may be given official status according to the 2006 Law on the Use of Languages (2011 est.)

Kuwait
Arabic (official), English widely spoken

Kyrgyzstan
Kyrgyz (official) 64.7%, Uzbek 13.6%, Russian (official) 12.5%, Dungun 1%, other 8.2% (1999 census)

Laos
Lao (official), French, English, various ethnic languages

Latvia
Latvian (official) 56.3%, Russian 33.8%, other 0.6% (includes Polish, Ukrainian, and Belarusian), unspecified 9.4% (2011 est.)

Lebanon
Arabic (official), French, English, Armenian

Lesotho
Sesotho (official) (southern Sotho), English (official), Zulu, Xhosa

Liberia
English 20% (official), some 20 ethnic group languages few of which can be written or used in correspondence

Libya
Arabic (official), Italian, English (all widely understood in the major cities); Berber (Nafusi, Ghadamis, Suknah, Awjilah, Tamasheq)

Liechtenstein
German 94.5% (official) (Alemannic is the main dialect), Italian 1.1%, other 4.3% (2010 est.)

Lithuania
Lithuanian (official) 82%, Russian 8%, Polish 5.6%, other 0.9%, unspecified 3.5% (2011 est.)

Luxembourg
Luxembourgish (official administrative language and national language (spoken vernacular)) 88.8%, French (official administrative language) 4.2%, Portuguese 2.3%, German (official administrative language) 1.1%, other 3.5% (2011 est.)

Macau
Cantonese 83.3%, Mandarin 5%, Hokkien 3.7%, English 2.3%, other Chinese dialects 2%, Tagalog 1.7%, Portuguese 0.7%, other 1.3%

note: Chinese and Portuguese are official languages (2011 est.)

Macedonia
Macedonian (official) 66.5%, Albanian (official) 25.1%, Turkish 3.5%, Roma 1.9%, Serbian 1.2%, other 1.8% (2002 est.)

Madagascar
French (official), Malagasy (official), English

Malawi
English (official), Chichewa (common), Chinyanja, Chiyao, Chitumbuka, Chilomwe, Chinkhonde, Chingoni, Chisena, Chitonga, Chinyakyusa, Chilambya

Malaysia
Bahasa Malaysia (official), English, Chinese (Cantonese, Mandarin, Hokkien, Hakka, Hainan, Foochow), Tamil, Telugu, Malayalam, Panjabi, Thai

note: in East Malaysia there are several indigenous languages; most widely spoken are Iban and Kadazan

Maldives
Dhivehi (official, dialect of Sinhala, script derived from Arabic), English (spoken by most government officials)

Mali
French (official), Bambara 46.3%, Peul/foulfoulbe 9.4%, Dogon 7.2%, Maraka/soninke 6.4%, Malinke 5.6%, Sonrhai/djerma 5.6%, Minianka 4.3%, Tamacheq 3.5%, Senoufo 2.6%, unspecified 0.6%, other 8.5%

note: Mali has 13 national languages in addition to its official language

Malta
Maltese (official) 90.1%, English (official) 6%, multilingual 3%, other 0.9% (2005 est.)

Marshall Islands
Marshallese (official) 98.2%, other languages 1.8% (1999 census)

note: English (official), widely spoken as a second language

Mauritania
Arabic (official and national), Pulaar, Soninke, Wolof (all national languages), French, Hassaniya (a variety of Arabic)

Mauritius
Creole 86.5%, Bhojpuri 5.3%, French 4.1%, two languages 1.4%, other 2.6% (includes English, the official language, which is spoken by less than 1% of the population), unspecified 0.1% (2011 est.)

Mexico
Spanish only 92.7%, Spanish and indigenous languages 5.7%, indigenous only 0.8%, unspecified 0.8%

note: indigenous languages include various Mayan, Nahuatl, and other regional languages (2005)

Micronesia, Federated States of
English (official and common language), Chuukese, Kosrean, Pohnpeian, Yapese, Ulithian, Woleaian, Nukuoro, Kapingamarangi

Moldova
Moldovan 58.8% (official; virtually the same as the Romanian language), Romanian 16.4%, Russian 16%, Ukrainian 3.8%, Gagauz 3.1% (a Turkish language), Bulgarian 1.1%, other 0.3%, unspecified 0.4%

note: percentages represent lanugage usually spoken (2004 est.)

Monaco
French (official), English, Italian, Monegasque

Mongolia
Khalkha Mongol 90% (official), Turkic, Russian (1999)

Montenegro
Serbian 42.9%, Montenegrin (official) 37%, Bosnian 5.3%, Albanian 5.3%, Serbo-Croat 2%, other 3.5%, unspecified 4% (2011 est.)

Montserrat
English

Morocco
Arabic (official), Berber languages (Tamazight (official), Tachelhit, Tarifit), French (often the language of business, government, and diplomacy)

Mozambique
Emakhuwa 25.3%, Portuguese (official) 10.7%, Xichangana 10.3%, Cisena 7.5%, Elomwe 7%, Echuwabo 5.1%, other Mozambican languages 30.1%, other 4% (1997 census)

Namibia
Oshiwambo languages 48.9%, Nama/Damara 11.3%, Afrikaans 10.4% (common language of most of the population and about 60% of the white population), Otjiherero languages 8.6%, Kavango languages 8.5%, Caprivi languages 4.8%, English (official) 3.4%, other African languages 2.3%, other 1.7%

note: Namibia has 13 recognized national languages, including 10 indigenous African languages and 3 Indo-European languages (2011 est.)

Nauru
Nauruan 93% (official, a distinct Pacific Island language), English 2% (widely understood, spoken, and used for most government and commercial purposes), other 5% (includes I-Kiribati 2% and Chinese 2%)

note: percentages represent main language spoken at home; Nauruan is spoken by 95% of the population, English by 66%, and other languages by 12% (2011 est.)

Nepal
Nepali (official) 44.6%, Maithali 11.7%, Bhojpuri 6%, Tharu 5.8%, Tamang 5.1%, Newar 3.2%, Magar 3%, Bajjika 3%, Urdu 2.6%, Avadhi 1.9%, Limbu 1.3%, Gurung 1.2%, other 10.4%, unspecified 0.2%

note: 123 languages reported as mother tongue in 2011 national census; many in government and business also speak English (2011 est.)

Netherlands
Dutch (official)

note: Frisian, Low Saxon, and Limburgish are recognized as regional languages under the European Charter for Regional or Minority Languages

New Caledonia
French (official), 33 Melanesian-Polynesian dialects

New Zealand
English (de facto official) 89.8%, Maori (de jure official) 3.5%, Samoan 2%, Hindi 1.6%, French 1.2%, Northern Chinese 1.2%, Yue 1%, Other or not stated 20.5%, New Zealand Sign Language (de jure official)

note: shares sum to 120.8% due to multiple responses on census (2013 est.)

Nicaragua
Spanish (official) 95.3%, Miskito 2.2%, Mestizo of the Caribbean coast 2%, other 0.5%

note: English and indigenous languages found on the Caribbean coast (2005 est.)

Nigeria
English (official), Hausa, Yoruba, Igbo (Ibo), Fulani, over 500 additional indigenous languages

Niger
French (official), Hausa, Djerma

Niue
Niuean (official) 46% (a Polynesian language closely related to Tongan and Samoan), Niuean and English 32%, English (official) 11%, Niuean and others 5%, other 6% (2011 est.)

Norfolk Island
English (official) 67.6%, other 32.4% (includes Norfolk Island 23.7%, which is a mixture of 18th century English and ancient Tahitian) (2011 est.)

Northern Mariana Islands
Philippine languages 32.8%, Chamorro (official) 24.1%, English (official) 17%, other Pacific island languages 10.1%, Chinese 6.8%, other Asian languages 7.3%, other 1.9% (2010 est.)

Norway
Bokmal Norwegian (official), Nynorsk Norwegian (official), small Sami- and Finnish-speaking minorities

note: Sami is an official language in nine municipalities

Oman
Arabic (official), English, Baluchi, Urdu, Indian dialects

Pakistan
Punjabi 48%, Sindhi 12%, Saraiki (a Punjabi variant) 10%, Pashto (alternate name, Pashtu) 8%, Urdu (official) 8%, Balochi 3%, Hindko 2%, Brahui 1%, English (official; lingua franca of Pakistani elite and most government ministries), Burushaski, and other 8%

Palau
Palauan (official on most islands) 66.6%, Carolinian 0.7%, other Micronesian 0.7%, English (official) 15.5%, Filipino 10.8%, Chinese 1.8%, other Asian 2.6%, other 1.3%

note: Sonsoral (Sonsoralese and English are official), Tobi (Tobi and English are official), and Angaur (Angaur, Japanese, and English are official) (2005 est.)

Panama
Spanish (official), indigenous languages (including Ngabe, Bugle, Kuna, Embera, Wounaan, Naso Tjerdi, and Bri Bri)

note: many Panamanians are bilingual

Papua New Guinea
Tok Pisin (official), English (official), Hiri Motu (official), some 836 indigenous languages spoken (about 12% of the world's total); most languages have fewer than 1,000 speakers

note: Tok Pisin, a creole language, is widely used and understood; English is spoken by 1%-2%; Hiri Motu is spoken by less than 2%

Paraguay
Spanish (official), Guarani (official)

Peru
Spanish (official) 84.1%, Quechua (official) 13%, Aymara (official) 1.7%, Ashaninka 0.3%, other native languages (includes a large number of minor Amazonian languages) 0.7%, other (includes foreign languages and sign language) 0.2% (2007 est.)

Philippines
Filipino (official; based on Tagalog) and English (official); eight major dialects - Tagalog, Cebuano, Ilocano, Hiligaynon or Ilonggo, Bicol, Waray, Pampango, and Pangasinan

Pitcairn Islands
English (official), Pitkern (mixture of an 18th century English dialect and a Tahitian dialect)

Poland
Polish (official) 98.2%, Silesian 1.4%, other 1.1%, unspecified 1.3%

note: data represents the language spoken at home; shares sum to more than 100% because some respondents gave more than one answer on the census; Poland ratified the European Charter for Regional or Minority Languages in 2009 recognizing Kashub as a regional language, Czech, Hebrew, Yiddish, Belarusian, Lithuanian, German, Armenian, Russian, Slovak, and Ukrainian as national minority languages, and Karaim, Lemko, Romani (Polska Roma and Bergitka Roma), and Tatar as ethnic minority languages (2011 est.)

Portugal
Portuguese (official), Mirandese (official, but locally used)

Puerto Rico
Spanish, English

Qatar
Arabic (official), English commonly used as a second language

Romania
Romanian (official) 85.4%, Hungarian 6.3%, Romany (Gypsy) 1.2%, other 1%, unspecified 6.1% (2011 est.)

Russia
Russian (official) 96.3%, Dolgang 5.3%, German 1.5%, Chechen 1%, Tatar 3%, other 10.3%

note: shares sum to more than 100% because some respondents gave more than one answer on the census (2010 est.)

Rwanda
Kinyarwanda only (official, universal Bantu vernacular) 93.2%, Kinyarwanda and other language(s) 6.2%, French (official) and other language(s) 0.1%, English (official) and other language(s) 0.1%, Swahili (or Kiswahili, used in commercial centers) 0.02%, other 0.03%, unspecified 0.3% (2002 est.)

Saint Barthelemy
French (primary), English

Saint Helena, Ascension, and Tristan da Cunha
English

Saint Kitts and Nevis
English (official)

Saint Lucia
English (official), French patois

Saint Martin
French (official), English, Dutch, French Patois, Spanish, Papiamento (dialect of Netherlands Antilles)

Saint Pierre and Miquelon
French (official)

Saint Vincent and the Grenadines
English, French patois

Samoa
Samoan (Polynesian) (official), English

San Marino
Italian

Sao Tome and Principe
Portuguese 98.4% (official), Forro 36.2%, Cabo Verdian 8.5%, French 6.8%, Angolar 6.6%, English 4.9%, Lunguie 1%, other (including sign language) 2.4%

note: shares sum to more than 100% because some respondents gave more than one answer on the census (2012 est.)

Saudi Arabia
Arabic (official)

Senegal
French (official), Wolof, Pulaar, Jola, Mandinka

Serbia
Serbian (official) 88.1%, Hungarian 3.4%, Bosnian 1.9%, Romany 1.4%, other 3.4%, undeclared or unknown 1.8%

note: Serbian, Hungarian, Slovak, Romanian, Croatian, and Rusyn all official in Vojvodina (2011 est.)

Seychelles
Seychellois Creole (official) 89.1%, English (official) 5.1%, French (official) 0.7%, other 3.8%, unspecified 1.4% (2010 est.)

Sierra Leone
English (official, regular use limited to literate minority), Mende (principal vernacular in the south), Temne (principal vernacular in the north), Krio (English-based Creole, spoken by the descendants of freed Jamaican slaves who were settled in the Freetown area, a lingua franca and a first language for 10% of the population but understood by 95%)

Singapore
Mandarin (official) 36.3%, English (official) 29.8%, Malay (official) 11.9%, Hokkien 8.1%, Tamil (official) 4.4%, Cantonese 4.1%, Teochew 3.2%, other Indian languages 1.2%, other Chinese dialects 1.1%, other 1.1% (2010 est.)

Sint Maarten
English (official) 67.5%, Spanish 12.9%, Creole 8.2%, Dutch (official) 4.2%, Papiamento (a Spanish-Portuguese-Dutch-English dialect) 2.2%, French 1.5%, other 3.5% (2001 census)

Slovakia
Slovak (official) 78.6%, Hungarian 9.4%, Roma 2.3%, Ruthenian 1%, other or unspecified 8.8% (2011 est.)

Slovenia
Slovenian (official) 91.1%, Serbo-Croatian 4.5%, other or unspecified 4.4%, Italian (official, only in municipalities where Italian national communities reside), Hungarian (official, only in municipalities where Hungarian national communities reside) (2002 census)

Solomon Islands
Melanesian pidgin (in much of the country is lingua franca), English (official but spoken by only 1%-2% of the population), 120 indigenous languages

Somalia
Somali (official), Arabic (official, according to the Transitional Federal Charter), Italian, English

South Africa
IsiZulu (official) 22.7%, IsiXhosa (official) 16%, Afrikaans (official) 13.5%, English (official) 9.6%, Sepedi (official) 9.1%, Setswana (official) 8%, Sesotho (official) 7.6%, Xitsonga (official) 4.5%, siSwati (official) 2.5%, Tshivenda (official) 2.4%, isiNdebele (official) 2.1%, sign language 0.5%, other 1.6% (2011 est.)

South Sudan
English (official), Arabic (includes Juba and Sudanese variants), regional languages include Dinka, Nuer, Bari, Zande, Shilluk

Spain
Castilian Spanish (official) 74%, Catalan 17%, Galician 7%, and Basque 2%

note: Catalan is official in Catalonia, the Balearic Islands, and the Valencian Community (where it is known as Valencian); in the northwest corner of Catalonia (Vall d'Aran), Aranese is official along with Catalan; Galician is official in Galicia; Basque is official in the Basque Country and in the Basque-speaking area of Navarre; Aragonese, Aranese Asturian, Basque, Calo, Catalan, Galician, and Valencian are recognized as regional languages under the European Charter for Regional or Minority Languages

Sri Lanka
Sinhala (official and national language) 74%, Tamil (national language) 18%, other 8%

note: English, spoken competently by about 10% of the population, is commonly used in government and is referred to as the link language in the constitution

Sudan
Arabic (official), English (official), Nubian, Ta Bedawie, Fur

note: program of "Arabization" in process

Suriname
Dutch (official), English (widely spoken), Sranang Tongo (Surinamese, sometimes called Taki-Taki, is native language of Creoles and much of the younger population and is lingua franca among others), Caribbean Hindustani (a dialect of Hindi), Javanese

Svalbard
Norwegian, Russian

Swaziland
English (official, used for government business), siSwati (official)

Sweden
Swedish (official), small Sami- and Finnish-speaking minorities

Switzerland
German (official) 64.9%, French (official) 22.6%, Italian (official) 8.3%, Serbo-Croatian 2.5%, Albanian 2.6%, Portuguese 3.4%, Spanish 2.2%, English 4.6%, Romansch (official) 0.5%, other 5.1%

note: German, French, Italian, and Romansch are all national and official languages; totals more than 100% because some respondents indicated more than one main principal language (2012 est.)

Syria
Arabic (official), Kurdish, Armenian, Aramaic, Circassian (widely understood); French, English (somewhat understood)

Taiwan
Mandarin Chinese (official), Taiwanese (Min), Hakka dialects

Tajikistan
Tajik (official), Russian widely used in government and business

note: different ethnic groups speak Uzbek, Kyrgyz, and Pashto

Tanzania
Kiswahili or Swahili (official), Kiunguja (name for Swahili in Zanzibar), English (official, primary language of commerce, administration, and higher education), Arabic (widely spoken in Zanzibar), many local languages

note: Kiswahili (Swahili) is the mother tongue of the Bantu people living in Zanzibar and nearby coastal Tanzania; although Kiswahili is Bantu in structure and origin, its vocabulary draws on a variety of sources including Arabic and English; it has become the lingua franca of central and eastern Africa; the first language of most people is one of the local languages

Thailand
Thai (official) 90.7%, Burmese 1.3%, other 8%

note: English is a secondary language of the elite (2010 est.)

Timor-Leste
Tetum (official), Portuguese (official), Indonesian, English

note: there are about 16 indigenous languages; Tetum, Galole, Mambae, and Kemak are spoken by a significant portion of the population

Togo
French (official, the language of commerce), Ewe and Mina (the two major African languages in the south), Kabye (sometimes spelled Kabiye) and Dagomba (the two major African languages in the north)

Tokelau
Tokelauan 93.5% (a Polynesian language), English 58.9%, Samoan 45.5%, Tuvaluan 11.6%, Kiribati 2.7%, other 2.5%, none 4.1%, unspecified 0.6%

ntoe: shares sum to more than 100% because some respondents gave more than one answer on the census (2011 ests.)

Tonga
English and Tongan 87%, Tongan (official) 10.7%, English (official) 1.2%, other 1.1%, uspecified 0.03% (2006 est.)

Trinidad and Tobago
English (official), Caribbean Hindustani (a dialect of Hindi), French, Spanish, Chinese

Tunisia
Arabic (official, one of the languages of commerce), French (commerce), Berber (Tamazight)

Turkey
Turkish (official), Kurdish, other minority languages

Turkmenistan
Turkmen (official) 72%, Russian 12%, Uzbek 9%, other 7%

Turks and Caicos Islands
English (official)

Tuvalu
Tuvaluan (official), English (official), Samoan, Kiribati (on the island of Nui)

Uganda
English (official national language, taught in grade schools, used in courts of law and by most newspapers and some radio broadcasts), Ganda or Luganda (most widely used of the Niger-Congo languages, preferred for native language publications in the capital and may be taught in school), other Niger-Congo languages, Nilo-Saharan languages, Swahili, Arabic

Ukraine
Ukrainian (official) 67.5%, Russian (regional language) 29.6%, other (includes small Crimean Tatar-, Moldavian-, and Hungarian-speaking minorities) 2.9% (2001 est.)

note: 2012 legislation enables a language spoken by at least 10% of an oblast's population to be given the status of "regional language," allowing for its use in courts, schools, and other government institutions; Ukrainian remains the country's only official nationwide language

United Arab Emirates
Arabic (official), Persian, English, Hindi, Urdu

United Kingdom
English

note: the following are recognized regional languages: Scots (about 30% of the population of Scotland), Scottish Gaelic (about 60,000 in Scotland), Welsh (about 20% of the population of Wales), Irish (about 10% of the population of Northern Ireland), Cornish (some 2,000 to 3,000 in Cornwall) (2012 est.)

United States
English 79.2%, Spanish 12.9%, other Indo-European 3.8%, Asian and Pacific island 3.3%, other 0.9% (2011 est.)

note: data represents the language spoken at home; the US has no official national language, but English has acquired official status in 31 of the 50 states; Hawaiian is an official language in the state of Hawaii

Uruguay
Spanish (official), Portunol, Brazilero (Portuguese-Spanish mix on the Brazilian frontier)

Uzbekistan
Uzbek (official) 74.3%, Russian 14.2%, Tajik 4.4%, other 7.1%

Vanuatu
local languages (more than 100) 63.2%, Bislama (official; creole) 33.7%, English (official) 2%, French (official) 0.6%, other 0.5% (2009 est.)

Venezuela
Spanish (official), numerous indigenous dialects

Vietnam
Vietnamese (official), English (increasingly favored as a second language), some French, Chinese, and Khmer, mountain area languages (Mon-Khmer and Malayo-Polynesian)

Virgin Islands
English 71.6%, Spanish or Spanish Creole 17.2%, French or French Creole 8.6%, other 2.5% (2010 est.)

Wallis and Futuna
Wallisian (indigenous Polynesian language) 58.9%, Futunian 30.1%, French (official) 10.8%, other 0.2% (2003 census)

West Bank
Arabic, Hebrew (spoken by Israeli settlers and many Palestinians), English (widely understood)

Western Sahara
Standard Arabic (national), Hassaniya Arabic, Moroccan Arabic

World
Mandarin Chinese 11.82%, Spanish 5.77%, English 4.67%, Hindi 3.62%, Arabic 3.3%, Portuguese 2.83%, Bengali 2.69%, Russian 2.33%, Japanese 1.7%, Javanese 1.15%, Standard German 1.09% (2014 est.)

note 1: percents are for "first language" speakers only; the six UN languages - Arabic, Chinese (Mandarin), English, French, Russian, and Spanish (Castilian) - are the mother tongue or second language of about half of the world's population, and are the official languages in more than half the states in the world; some 150 to 200 languages have more than a million speakers

note 2: all told, there are an estimated 7,100 languages spoken in the world; aproximately 80% of these languages are spoken by less than 100,000 people; about 140 languages are spoken by less than 10 people; communities that are isolated from each other in mountainous regions often develop multiple languages; Papua New Guinea, for example, boasts about 839 separate languages

note 3: approximately 2,300 languages are spoken in Asia, 2,140, in Africa, 1,300 in the Pacific, 1,060 in the Americas, and 280 in Europe (2015)

Yemen
Arabic (official)

Zambia
Bembe 33.4%, Nyanja 14.7%, Tonga 11.4%, Lozi 5.5%, Chewa 4.5%, Nsenga 2.9%, Tumbuka 2.5%, Lunda (North Western) 1.9%, Kaonde 1.8%, Lala 1.8%, Lamba 1.8%, English (official) 1.7%, Luvale 1.5%, Mambwe 1.3%, Namwanga 1.2%, Lenje 1.1%, Bisa 1%, other 9.2%, unspecified 0.4%

note: Zambia is said to have over 70 languages, although many of these may be considered dialects; all of Zambia's major languages are members of the Bantu family (2010 est.)

Zimbabwe
Shona (official; most widely spoken), Ndebele (official, second most widely spoken), English (official; traditionally used for official business), 13 minority languages (official; includes Chewa, Chibarwe, Kalanga, Koisan, Nambya, Ndau, Shangani, sign language, Sotho, Tonga, Tswana, Venda, and Xhosa)

About CIA

                           Today's CIA

                           Leadership

                           CIA Vision, Mission & Values

                           Headquarters Tour

                           CIA Museum

                           History of the CIA

                           FAQs

                           NoFEAR Act

                           Site Policies

Careers & Internships

                           Career Opportunities

                           Student Opportunities

                           Application Process

                           Life at CIA

                           Diversity

                           Military Transition

                           Diversions & Information

                           FAQs

Offices of CIA

                           Intelligence & Analysis

                           Clandestine Service

                           Science & Technology

                           Support to Mission

                           Human Resources

                           Public Affairs

                           General Counsel

                           Equal Employment Opportunity

                           Congressional Affairs

                           Inspector General

                           Military Affairs

News & Information

                           Press Releases & Statements

                           Speeches & Testimony

                           CIA & the War on Terrorism

                           Featured Story Archive

                           What’s New Archive

                           Your News

Library

                           Publications

                           Center for the Study of Intelligence

                           Freedom of Information Act Electronic Reading Room

                           Kent Center Occasional Papers

                           Intelligence Literature

                           Reports

                           Related Links

                           Video Center

Kids' Zone

                           K-5th Grade

                           6-12th Grade

                           Parents & Teachers

                           Games

                           Related Links

                           Privacy Statement

Connect with CIA

CIA YouTube

CIA Flickr PhotoStream

RSS

Contact Us

* Required plugins

Adobe® Flash Player

Adobe® Reader®

MS Word Viewer

Footer Navigation

Privacy

Copyright

Site Policies

USA.gov

FOIA

DNI.gov

NoFEAR Act

Inspector General

Mobile Site

Contact CIA

Site Map

GO TOP


text:
<?php

namespace Symfony\Component\DependencyInjection\Loader\Configurator;

use Symfony\Component\Serializer\DataCollector\SerializerDataCollector;
use Symfony\Component\Serializer\Debug\TraceableSerializer;

return static function (ContainerConfigurator $container) {
    $container->services()
        ->set('debug.serializer', TraceableSerializer::class)
            ->decorate('serializer', null, 255)
            ->args([
                service('debug.serializer.inner'),
                service('serializer.data_collector'),
            ])

        ->set('serializer.data_collector', SerializerDataCollector::class)
            ->tag('data_collector', [
                'template' => '@WebProfiler/Collector/serializer.html.twig',
                'id' => 'serializer',
            ])
    ;
};

redpajama_set_name: RedPajamaGithub


text:
package com.facebook.buck.core.model.actiongraph.computation;

import com.facebook.buck.core.cell.CellProvider;
import com.facebook.buck.core.model.BuildTarget;
import com.facebook.buck.core.model.actiongraph.ActionGraph;
import com.facebook.buck.core.model.actiongraph.ActionGraphAndBuilder;
import com.facebook.buck.core.model.actiongraph.computation.ActionGraphFactory.ActionGraphCreationLifecycleListener;
import com.facebook.buck.core.model.targetgraph.TargetGraph;
import com.facebook.buck.core.model.targetgraph.TargetNode;
import com.facebook.buck.core.rules.ActionGraphBuilder;
import com.facebook.buck.core.rules.BuildRule;
import com.facebook.buck.core.rules.resolver.impl.MultiThreadedActionGraphBuilder;
import com.facebook.buck.core.rules.transformer.TargetNodeToBuildRuleTransformer;
import com.facebook.buck.core.util.graph.AbstractBottomUpTraversal;
import com.facebook.buck.core.util.log.Logger;
import com.facebook.buck.util.CloseableMemoizedSupplier;
import com.google.common.base.Throwables;
import java.util.HashMap;
import java.util.Objects;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.CompletionException;
import java.util.concurrent.ForkJoinPool;

public class ParallelActionGraphFactory implements ActionGraphFactoryDelegate {
  private static final Logger LOG = Logger.get(ParallelActionGraphFactory.class);

  private final CloseableMemoizedSupplier<ForkJoinPool> poolSupplier;
  private final CellProvider cellProvider;

  public ParallelActionGraphFactory(
      CloseableMemoizedSupplier<ForkJoinPool> poolSupplier, CellProvider cellProvider) {
    this.poolSupplier = poolSupplier;
    this.cellProvider = cellProvider;
  }

  @Override
  public ActionGraphAndBuilder create(
      TargetNodeToBuildRuleTransformer transformer,
      TargetGraph targetGraph,
      ActionGraphCreationLifecycleListener actionGraphCreationLifecycleListener) {
    ForkJoinPool pool = poolSupplier.get();
    ActionGraphBuilder graphBuilder =
        new MultiThreadedActionGraphBuilder(pool, targetGraph, transformer, cellProvider);
    HashMap<BuildTarget, CompletableFuture<BuildRule>> futures = new HashMap<>();

    actionGraphCreationLifecycleListener.onCreate(graphBuilder);

    LOG.debug("start target graph walk");
    new AbstractBottomUpTraversal<TargetNode<?>, RuntimeException>(targetGraph) {
      @Override
      public void visit(TargetNode<?> node) {
        // If we're loading this node from cache, we don't need to wait on our children, as the
        // entire subgraph will be loaded from cache.
        CompletableFuture<BuildRule>[] depFutures =
            targetGraph
                .getOutgoingNodesFor(node)
                .stream()
                .map(dep -> Objects.requireNonNull(futures.get(dep.getBuildTarget())))
                .<CompletableFuture<BuildRule>>toArray(CompletableFuture[]::new);
        futures.put(
            node.getBuildTarget(),
            CompletableFuture.allOf(depFutures)
                .thenApplyAsync(ignored -> graphBuilder.requireRule(node.getBuildTarget()), pool));
      }
    }.traverse();

    // Wait for completion. The results are ignored as we only care about the rules populated in
    // the graphBuilder, which is a superset of the rules generated directly from target nodes.
    try {
      CompletableFuture.allOf(futures.values().toArray(new CompletableFuture[0])).join();
    } catch (CompletionException e) {
      Throwables.throwIfUnchecked(e.getCause());
      throw new IllegalStateException("unexpected checked exception", e);
    }
    LOG.debug("end target graph walk");

    return ActionGraphAndBuilder.builder()
        .setActionGraph(new ActionGraph(graphBuilder.getBuildRules()))
        .setActionGraphBuilder(graphBuilder)
        .build();
  }
}


text: homebrew_cask 'caffeine'


text:
/* global graph,nodes,uniqueNum,alert,VW,createCell,createEdge */
"use strict";
var jsonFile = require('jsonfile');
var gui = require('nw.gui');
var $ = require('jquery');

var win = gui.Window.get();

function initMenu(){
	var menubar = new gui.Menu({ type: 'menubar' });
	var fileMenu = new gui.Menu();
	fileMenu.append(new gui.MenuItem({
	    label: 'New',
	    click: function() {
	    	clearGraph();
	    }
	}));
	fileMenu.append(new gui.MenuItem({
	    label: 'Open',
	    click: function() {
	    	$("#openFileDialog").trigger("click");
	    }
	}));
	fileMenu.append(new gui.MenuItem({
	    label: 'Save',
	    click: function() {
	    	$("#saveFileDialog").trigger("click");
	    }
	}));
	fileMenu.append(new gui.MenuItem({
	    label: 'Exit',
	    click: function() {
	        gui.App.quit();
	    }
	}));

	menubar.append(new gui.MenuItem({ label: 'File', submenu: fileMenu}));
	win.menu = menubar;
}

$("#openFileDialog").change(function(key){
	loadGraph($(this).val());
	$("#openFileDialog").val("");
});
$("#saveFileDialog").change(function(key){
	saveGraph($(this).val());
	$("#saveFileDialog").val("");
});

initMenu();

function clearGraph(){
	var keys = Object.keys(graph.nodes);
	for(let i=0; i<keys.length; i++){
		$("#"+keys[i]).remove();
		if(graph.nodes[keys[i]].outputs){
			for(let j=0; j<graph.nodes[keys[i]].outputs.length; j++){
				$("#"+keys[i]+graph.nodes[keys[i]].outputs[j]).remove();
			}
		}
	}
	graph.nodes = {}; // jshint ignore:line
	uniqueNum = 1; // jshint ignore:line
}

function saveGraph(graphName){
	var toSave = {};
	for(let key of Object.keys(graph.nodes)){
		toSave[key] = graph.nodes[key].getSaveData();
	}
	jsonFile.writeFile(graphName, toSave, function(err){
		if(err){
			console.log(err);
			alert("Save failed: "+err);
		}
	});
}

function loadGraph(graphName){
	if(!graphName){
		return;
	}
	clearGraph();
	jsonFile.readFile(graphName, function(err,obj){
		if(!err){
			graph.nodes = {}; // jshint ignore:line
			var keys = Object.keys(obj);
			uniqueNum = keys.length + 1; // jshint ignore:line
			for(let i=0; i<keys.length; i++){
				let id = keys[i];
				let x = parseInt(obj[id].left.split('vw'))*VW;
				let y = parseInt(obj[id].top.split('vw'))*VW;
				let color = obj[id].color;
				let value = obj[id].value;
				createCell(x,y,color,id,value);
				graph.nodes[id].outputs = obj[id].outputs;
				graph.nodes[id].inputs = obj[id].inputs;
				graph.nodes[id].label = obj[id].label;
			}
			for(let i=0; i<keys.length; i++){
				let id = keys[i];
				for(let j=0; j<graph.nodes[id].outputs.length; j++){
					createEdge(id,graph.nodes[id].outputs[j]);
				}
			}
		}
		else{
			console.log(err);
			alert("Load failed: "+err);
		}
	});
}


text:
package io.github.tjheslin1.patterdale.metrics.probe;

import io.github.tjheslin1.patterdale.config.RuntimeParameters;
import io.github.tjheslin1.patterdale.database.DBConnection;
import io.github.tjheslin1.patterdale.database.DBConnectionPool;
import org.assertj.core.api.WithAssertions;
import org.junit.Test;
import org.slf4j.Logger;
import testutil.WithMockito;

import java.io.IOException;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.ResultSetMetaData;
import java.util.List;
import java.util.concurrent.Future;
import java.util.concurrent.TimeoutException;

import static io.github.tjheslin1.patterdale.metrics.probe.Probe.probe;
import static java.util.Arrays.asList;
import static java.util.Collections.singletonList;
import static java.util.concurrent.TimeUnit.SECONDS;

public class ListOracleSQLProbeTest implements WithAssertions, WithMockito {

    private static final Probe PROBE = probe("name", "SQL", "exists", "name", "label");

    private final ResultSet resultSet = mock(ResultSet.class);
    private final ResultSetMetaData resultSetMetaData = mock(ResultSetMetaData.class);
    private final PreparedStatement preparedStatement = mock(PreparedStatement.class);
    private final Connection connection = mock(Connection.class);
    private final DBConnection dbConnection = mock(DBConnection.class);
    private final DBConnectionPool dbConnectionPool = mock(DBConnectionPool.class);
    private final Future<DBConnectionPool> futureConnectionPool = mock(Future.class);
    private final RuntimeParameters runtimeParameters = mock(RuntimeParameters.class);
    private final Logger logger = mock(Logger.class);

    private final ListOracleSQLProbe listOracleSQLProbe = new ListOracleSQLProbe(PROBE, futureConnectionPool, runtimeParameters, logger);

    @Test
    public void probeReturnsMultipleSuccess() throws Exception {
        when(resultSet.getMetaData()).thenReturn(resultSetMetaData);
        when(resultSet.next()).thenReturn(true, true, false);
        when(resultSetMetaData.getColumnCount()).thenReturn(2);
        when(resultSet.getDouble(1)).thenReturn(4.5, 6.7);
        when(resultSet.getString(2)).thenReturn("example SQL", "example SQL2");
        when(preparedStatement.executeQuery()).thenReturn(resultSet);
        when(connection.prepareStatement(any())).thenReturn(preparedStatement);
        when(dbConnection.connection()).thenReturn(connection);
        when(futureConnectionPool.get(anyLong(), eq(SECONDS))).thenReturn(dbConnectionPool);
        when(dbConnectionPool.pool()).thenReturn(dbConnection);
        when(runtimeParameters.probeConnectionWaitInSeconds()).thenReturn(10);

        List<ProbeResult> probeResults = listOracleSQLProbe.probes();

        assertThat(probeResults).containsExactly(
                new ProbeResult(4.5, PROBE, singletonList("example SQL")),
                new ProbeResult(6.7, PROBE, singletonList("example SQL2"))
        );
    }

    @Test
    public void probeAssumesFirstColumnIsProbeValueAndRemainingColumnsAreDynamicLabels() throws Exception {
        when(resultSet.getMetaData()).thenReturn(resultSetMetaData);
        when(resultSet.next()).thenReturn(true, false);
        when(resultSetMetaData.getColumnCount()).thenReturn(3);
        when(resultSet.getDouble(1)).thenReturn(4.5);
        when(resultSet.getString(2)).thenReturn("example SQL");
        when(resultSet.getString(3)).thenReturn("dynamicLabel3");
        when(preparedStatement.executeQuery()).thenReturn(resultSet);
        when(connection.prepareStatement(any())).thenReturn(preparedStatement);
        when(dbConnection.connection()).thenReturn(connection);
        when(futureConnectionPool.get(anyLong(), eq(SECONDS))).thenReturn(dbConnectionPool);
        when(dbConnectionPool.pool()).thenReturn(dbConnection);
        when(runtimeParameters.probeConnectionWaitInSeconds()).thenReturn(10);

        List<ProbeResult> probeResults = listOracleSQLProbe.probes();

        assertThat(probeResults).containsExactly(
                new ProbeResult(4.5, PROBE, asList("example SQL", "dynamicLabel3"))
        );
    }

    @Test
    public void probeQueryTimesOutReturningEmptyProbeResultList() throws Exception {
        when(preparedStatement.executeQuery()).thenThrow(TimeoutException.class);
        when(connection.prepareStatement(any())).thenReturn(preparedStatement);
        when(dbConnection.connection()).thenReturn(connection);
        when(dbConnectionPool.pool()).thenReturn(dbConnection);

        assertThat(listOracleSQLProbe.probes()).isEmpty();
    }

    @Test
    public void probeFailsAndReturnsEmptyProbeResultList() throws Exception {
        when(preparedStatement.executeQuery()).thenThrow(IOException.class);
        when(connection.prepareStatement(any())).thenReturn(preparedStatement);
        when(dbConnection.connection()).thenReturn(connection);
        when(dbConnectionPool.pool()).thenReturn(dbConnection);

        assertThat(listOracleSQLProbe.probes()).isEmpty();
    }
}


text:
<?php

namespace Mage\Rating\Test\Handler;

use Mage\Adminhtml\Test\Handler\Extractor;
use Magento\Mtf\Fixture\FixtureInterface;
use Magento\Mtf\Handler\Curl as AbstractCurl;
use Magento\Mtf\Util\Protocol\CurlInterface;
use Magento\Mtf\Util\Protocol\CurlTransport;
use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator;

/**
 * Curl handler for creating product Rating through backend.
 */
class Curl extends AbstractCurl implements RatingInterface
{
    /**
     * Mapping stores value.
     *
     * @var array
     */
    protected $mappingStores = [
        'Main Website/Main Website Store/Default Store View' => 1,
    ];

    /**
     * Rating options.
     *
     * @var array
     */
    protected $options = [
        'add_1' => 1,
        'add_2' => 2,
        'add_3' => 3,
        'add_4' => 4,
        'add_5' => 5,
    ];

    /**
     * Post request for creating product Rating in backend.
     *
     * @param FixtureInterface|null $rating
     * @return array
     * @throws \Exception
     */
    public function persist(FixtureInterface $rating = null)
    {
        $url = $_ENV['app_backend_url'] . 'rating/save';
        $curl = new BackendDecorator(new CurlTransport(), $this->_configuration);
        $data = $this->replaceMappingData($this->prepareData($rating->getData()));
        $curl->write(CurlInterface::POST, $url, '1.1', [], $data);
        $response = $curl->read();
        $curl->close();
        if (!strpos($response, 'class="success-msg"')) {
            throw new \Exception(
                'Product Rating entity creating by curl handler was not successful! Response:' . $response
            );
        }

        return ['rating_id' => $this->getProductRatingId()];
    }

    /**
     * Prepare POST data for creating rating request.
     *
     * @param array $data
     * @return array
     */
    protected function prepareData(array $data)
    {
        if (isset($data['stores'])) {
            foreach ($data['stores'] as $key => $store) {
                if (isset($this->mappingStores[$store])) {
                    $data['stores'][$key] = $this->mappingStores[$store];
                }
            }
        }
        $data['option_title'] = $this->options;

        return $data;
    }

    /**
     * Get product Rating id.
     *
     * @return mixed
     */
    protected function getProductRatingId()
    {
        $url = 'rating/index/sort/rating_id/dir/desc/';
        $regex = '`rating\/edit\/id\/(\d+)`';
        $extractor = new Extractor($url, $regex);
        $match = $extractor->getData();

        return empty($match[1]) ? null : $match[1];
    }
}