{"id":100,"date":"2022-10-03T20:16:55","date_gmt":"2022-10-03T20:16:55","guid":{"rendered":"http:\/\/learnlearn.uk\/ibcs\/?page_id=100"},"modified":"2022-10-03T20:21:16","modified_gmt":"2022-10-03T20:21:16","slug":"hexadecimal","status":"publish","type":"page","link":"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/","title":{"rendered":"Hexadecimal"},"content":{"rendered":"<div class=\"responsive-tabs\">\n<h2 class=\"tabtitle\">Introduction<\/h2>\n<div class=\"tabcontent\">\n\n<h3>Why do we use it hexadecimal?<\/h3>\n<p>Binary is very difficult for humans to read (especially larger numbers) but computers work in binary, so any usage where you need to be able to inspect and edit the binary directly (such as in machine code\/ assembly language) then humans need to be able to read the binary easily and accurately. This is where hexadecimal comes in :<\/p>\n<ul>\n<li>Hexadecimal allows humans to interact with binary in a human readable form.<\/li>\n<li>Hexadecimal is compact and easy for humans to read<\/li>\n<li>Large numbers can be represented in a smaller number of digits, making them easier and more accurately read by humans.<\/li>\n<li>Hexadecimal can be easily converted to binary and vice verse.<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<h3>How does hexadecimal work?<\/h3>\n<p>In the normal human counting system we use a base 10 number system, meaning that the each extra digit increases in powers of 10 each time:<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"wp-image-951 size-full\" src=\"https:\/\/learnlearn.uk\/gcsecs\/wp-content\/uploads\/sites\/8\/2018\/01\/denary-example.png?_t=1598666746\" alt=\"\" width=\"818\" height=\"190\" \/><\/p>\n<p>Hexadecimal is a Base 16 number system, meaning that increases in powers of 16, with each digit being one of 16 different combinations.<\/p>\n<p>The hexadecimal number consists of:<\/p>\n<ul>\n<li>0 = 0<\/li>\n<li>1 = 1<\/li>\n<li>2 =2<\/li>\n<li>3 = 3<\/li>\n<li>4 = 4<\/li>\n<li>5 = 5<\/li>\n<li>6 = 6<\/li>\n<li>7 =7<\/li>\n<li>8 = 8<\/li>\n<li>9 = 9<\/li>\n<li>A = 10<\/li>\n<li>B = 11<\/li>\n<li>C = 12<\/li>\n<li>D = 13<\/li>\n<li>E = 14<\/li>\n<li>F = 15<\/li>\n<\/ul>\n<p><strong>Why do we use a to f instead of 11 to 15?<\/strong><\/p>\n<p>We can&#8217;t use 11 to 15 because we wouldn&#8217;t know what number it represented. The Digits <strong>13\u00a0<\/strong> could be 13 or it could be 19\u00a0 (1 * 16 + 3), this is because denary numbers greater than 9 use 2 digits instead of one digit.<\/p>\n<p>&nbsp;<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-full wp-image-952\" src=\"https:\/\/learnlearn.uk\/gcsecs\/wp-content\/uploads\/sites\/8\/2018\/01\/hex-example.png\" alt=\"\" width=\"682\" height=\"226\" \/><\/p>\n<p>&nbsp;<\/p>\n\n<\/div><h2 class=\"tabtitle\">HTML\/CSS<\/h2>\n<div class=\"tabcontent\">\n\n<h3>Hexadecimal in HTML &amp; CSS<\/h3>\n<p>Hexadecimal is used to represent RGB colors in HTML and in CSS. The video below shows how it works.<\/p>\n<div class=\"nv-iframe-embed\">\n<div class=\"container-lazyload preview-lazyload container-youtube js-lazyload--not-loaded\"><a href=\"https:\/\/www.youtube.com\/watch?v=c56x1aj2CPA\" class=\"lazy-load-youtube preview-lazyload preview-youtube\" data-video-title=\"How Do HEX Color Codes Work? (in 60 seconds)\" title=\"Play video &quot;How Do HEX Color Codes Work? (in 60 seconds)&quot;\">https:\/\/www.youtube.com\/watch?v=c56x1aj2CPA<\/a><noscript>Video can&#8217;t be loaded because JavaScript is disabled: <a href=\"https:\/\/www.youtube.com\/watch?v=c56x1aj2CPA\" title=\"How Do HEX Color Codes Work? (in 60 seconds)\">How Do HEX Color Codes Work? (in 60 seconds) (https:\/\/www.youtube.com\/watch?v=c56x1aj2CPA)<\/a><\/noscript><\/div>\n<\/div>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n\n<\/div><h2 class=\"tabtitle\">MAC<\/h2>\n<div class=\"tabcontent\">\n\n<h3>Media Access Control Addresses<\/h3>\n<p>MAC addresses are unique identifier codes given to each piece of network enable hardware created. They are issued by the manufacturer of the hardware when the device is created and the first part of the MAC address indicates the manuafacturer.<\/p>\n<p>MAC addresses consist of 6 pairs of hexadecimal digits, separated by a colon.<\/p>\n<p><strong>Example: dd:f2:c2:a1:2b:cd<\/strong><\/p>\n<p>Each pair can be one of 256 possible values (0-255) so the total number of possible MAC addresses are 256 to the power of 6 = 281,474,976,710,656 possible MAC addresses.<\/p>\n<p>&nbsp;<\/p>\n<h3>Why are MAC addresses displayed in HEX?<\/h3>\n<p>MAC addresses are displayed in hex a because the codes are too long for humans to be able to read accurately in binary.<\/p>\n<p>The MAC address above in binary would be\u00a0110111011111001011000010101000010010101111001101<\/p>\n<p>This is incredibly difficult for a human to read\/remember.<\/p>\n<div class=\"nv-iframe-embed\">\n<div class=\"container-lazyload preview-lazyload container-youtube js-lazyload--not-loaded\"><a href=\"https:\/\/www.youtube.com\/watch?v=UrG7RTWIJak\" class=\"lazy-load-youtube preview-lazyload preview-youtube\" data-video-title=\"What is a MAC Address?\" title=\"Play video &quot;What is a MAC Address?&quot;\">https:\/\/www.youtube.com\/watch?v=UrG7RTWIJak<\/a><noscript>Video can&#8217;t be loaded because JavaScript is disabled: <a href=\"https:\/\/www.youtube.com\/watch?v=UrG7RTWIJak\" title=\"What is a MAC Address?\">What is a MAC Address? (https:\/\/www.youtube.com\/watch?v=UrG7RTWIJak)<\/a><\/noscript><\/div>\n<\/div>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n\n<\/div><h2 class=\"tabtitle\">Assembly\/MC<\/h2>\n<div class=\"tabcontent\">\n\n<h3>Assembly Language &amp; Machine Code<\/h3>\n<p>Hexadecimal is used when humans are reading\/editing machine code or assembly language. Computers can only interpret instructions written in binary, so all instructions need to be written in binary. Humans would find this incredibly slow and difficult to do so we display the hexadecimal equivalent to humans to read. This means that humans can edit machine code.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/learnlearn.uk\/gcsecs\/wp-content\/uploads\/sites\/8\/2018\/01\/Apple_II_Monitor.png\" \/><\/p>\n<p><a href=\"https:\/\/en.wikipedia.org\/wiki\/Machine_code_monitor#\/media\/File:Apple_II_Monitor.png\">Source: Wikipedia<\/a><\/p>\n\n<\/div><h2 class=\"tabtitle\">Error Codes\/Logs<\/h2>\n<div class=\"tabcontent\">\n\n<h3>Error \/ Debugging Codes<\/h3>\n<p>When your computer crashes it often displays an error code in Hexadecimal. This hexadecimal code contains the hexadecimal representation of the memory address where the error occurred.<\/p>\n<p>This allows engineers to quickly debug the code.<\/p>\n<p>&nbsp;<\/p>\n<div id=\"attachment_138\" style=\"width: 760px\" class=\"wp-caption alignnone\"><a href=\"https:\/\/learnlearn.uk\/igcsecs\/wp-content\/uploads\/sites\/23\/2020\/11\/hexadecimal-error-codes-igcse-gcse-computer-science.jpg\"><img aria-describedby=\"caption-attachment-138\" decoding=\"async\" loading=\"lazy\" class=\"size-large wp-image-138\" src=\"https:\/\/learnlearn.uk\/igcsecs\/wp-content\/uploads\/sites\/23\/2020\/11\/hexadecimal-error-codes-igcse-gcse-computer-science-1024x538.jpg\" alt=\"\" width=\"750\" height=\"394\" \/><\/a><p id=\"caption-attachment-138\" class=\"wp-caption-text\">Notice the hexadecimal memory location where the error occurred?<\/p><\/div>\n\n<\/div><h2 class=\"tabtitle\">Resources<\/h2>\n<div class=\"tabcontent\">\n\n<p><a href=\"https:\/\/www.worksheetworks.com\/math\/numbers\/systems.html\">Worksheet with With explanations<\/a><\/p>\n<p><a href=\"https:\/\/www.saddleback.edu\/faculty\/msierakowski\/binhex_worksheet.pdf\">Test sheet<\/a><\/p>\n<p><a href=\"https:\/\/www.worksheetworks.com\/math\/numbers\/systems.html\">Worksheet generator<\/a><\/p>\n<p><a href=\"http:\/\/www.hexinvaders.com\/\">Hex Invaders Game<\/a><\/p>\n<p><strong>IGCSE Past Paper Exam Questions (Replace with IB Questions)<\/strong><\/p>\n<p><a href=\"https:\/\/pastpapers.papacambridge.com\/viewer\/caie\/cambridge-upper-secondary-igcse-computer-science-0478-2016-jun-0478-s16-qp-12-pdf\">0478\/12 &#8211; Paper 1 Theory May\/June 2016 Qn3<\/a><\/p>\n<p><a href=\"https:\/\/pastpapers.papacambridge.com\/viewer\/caie\/cambridge-upper-secondary-igcse-computer-science-0478-2016-nov-0478-w16-qp-11-pdf\">0478\/11 &#8211; Paper 1 Theory October\/November 2016 qn 10a\/b<\/a><\/p>\n<p><a href=\"https:\/\/pastpapers.papacambridge.com\/viewer\/caie\/cambridge-upper-secondary-igcse-computer-science-0478-2017-jun-0478-s17-qp-11-pdf\">0478\/11 &#8211; Paper 1 Theory May\/June 2017 &#8211; Qn 1<\/a><\/p>\n<p><a href=\"https:\/\/pastpapers.papacambridge.com\/viewer\/caie\/cambridge-upper-secondary-igcse-computer-science-0478-2017-jun-0478-s17-qp-13-pdf\">0478\/13 &#8211; Paper 1 Theory May\/June 2017 Qn1<\/a><\/p>\n<p><a href=\"https:\/\/pastpapers.papacambridge.com\/viewer\/caie\/cambridge-upper-secondary-igcse-computer-science-0478-2017-mar-0478-m17-qp-12-pdf\">0478\/12 &#8211; Paper 1 Theory February\/March 2017<\/a>\u00a0Qn12<\/p>\n<p><a href=\"https:\/\/pastpapers.papacambridge.com\/viewer\/caie\/cambridge-upper-secondary-igcse-computer-science-0478-2017-nov-0478-w17-qp-12-pdf\">0478\/12 &#8211; Paper 1 Theory October\/November 2017 Qn1\u00a0 &#8211; hex robotics\u00a0<\/a><\/p>\n<\/div><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Why do we use it hexadecimal? Binary is very difficult for humans to read (especially larger numbers) but computers work in binary, so any usage where you need to be able to inspect and edit the binary directly (such as in machine code\/ assembly language) then humans need to be able to read the binary&hellip;&nbsp;<a href=\"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/\" class=\"\" rel=\"bookmark\">Read More &raquo;<span class=\"screen-reader-text\">Hexadecimal<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"neve_meta_sidebar":"","neve_meta_container":"","neve_meta_enable_content_width":"","neve_meta_content_width":70,"neve_meta_title_alignment":"","neve_meta_author_avatar":"","neve_post_elements_order":"","neve_meta_disable_header":"","neve_meta_disable_footer":"","neve_meta_disable_title":""},"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.6 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Hexadecimal - IB Computer Science<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/\" \/>\n<meta property=\"og:locale\" content=\"en_GB\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Hexadecimal - IB Computer Science\" \/>\n<meta property=\"og:description\" content=\"Why do we use it hexadecimal? Binary is very difficult for humans to read (especially larger numbers) but computers work in binary, so any usage where you need to be able to inspect and edit the binary directly (such as in machine code\/ assembly language) then humans need to be able to read the binary&hellip;&nbsp;Read More &raquo;Hexadecimal\" \/>\n<meta property=\"og:url\" content=\"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/\" \/>\n<meta property=\"og:site_name\" content=\"IB Computer Science\" \/>\n<meta property=\"article:modified_time\" content=\"2022-10-03T20:21:16+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/learnlearn.uk\/gcsecs\/wp-content\/uploads\/sites\/8\/2018\/01\/denary-example.png?_t=1598666746\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Estimated reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/\",\"url\":\"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/\",\"name\":\"Hexadecimal - IB Computer Science\",\"isPartOf\":{\"@id\":\"https:\/\/learnlearn.uk\/ibcs\/#website\"},\"datePublished\":\"2022-10-03T20:16:55+00:00\",\"dateModified\":\"2022-10-03T20:21:16+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/#breadcrumb\"},\"inLanguage\":\"en-GB\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"IB Computer Science\",\"item\":\"https:\/\/learnlearn.uk\/ibcs\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Hexadecimal\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/learnlearn.uk\/ibcs\/#website\",\"url\":\"https:\/\/learnlearn.uk\/ibcs\/\",\"name\":\"IB Computer Science\",\"description\":\"- learnlearn..uk\",\"publisher\":{\"@id\":\"https:\/\/learnlearn.uk\/ibcs\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/learnlearn.uk\/ibcs\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-GB\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/learnlearn.uk\/ibcs\/#organization\",\"name\":\"IB Computer Science\",\"url\":\"https:\/\/learnlearn.uk\/ibcs\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-GB\",\"@id\":\"https:\/\/learnlearn.uk\/ibcs\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/learnlearn.uk\/ibcs\/wp-content\/uploads\/sites\/25\/2022\/09\/LearnLearnLogowhite-300x41.png\",\"contentUrl\":\"https:\/\/learnlearn.uk\/ibcs\/wp-content\/uploads\/sites\/25\/2022\/09\/LearnLearnLogowhite-300x41.png\",\"width\":300,\"height\":41,\"caption\":\"IB Computer Science\"},\"image\":{\"@id\":\"https:\/\/learnlearn.uk\/ibcs\/#\/schema\/logo\/image\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Hexadecimal - IB Computer Science","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/","og_locale":"en_GB","og_type":"article","og_title":"Hexadecimal - IB Computer Science","og_description":"Why do we use it hexadecimal? Binary is very difficult for humans to read (especially larger numbers) but computers work in binary, so any usage where you need to be able to inspect and edit the binary directly (such as in machine code\/ assembly language) then humans need to be able to read the binary&hellip;&nbsp;Read More &raquo;Hexadecimal","og_url":"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/","og_site_name":"IB Computer Science","article_modified_time":"2022-10-03T20:21:16+00:00","og_image":[{"url":"https:\/\/learnlearn.uk\/gcsecs\/wp-content\/uploads\/sites\/8\/2018\/01\/denary-example.png?_t=1598666746"}],"twitter_card":"summary_large_image","twitter_misc":{"Estimated reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/","url":"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/","name":"Hexadecimal - IB Computer Science","isPartOf":{"@id":"https:\/\/learnlearn.uk\/ibcs\/#website"},"datePublished":"2022-10-03T20:16:55+00:00","dateModified":"2022-10-03T20:21:16+00:00","breadcrumb":{"@id":"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/#breadcrumb"},"inLanguage":"en-GB","potentialAction":[{"@type":"ReadAction","target":["https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/learnlearn.uk\/ibcs\/hexadecimal\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"IB Computer Science","item":"https:\/\/learnlearn.uk\/ibcs\/"},{"@type":"ListItem","position":2,"name":"Hexadecimal"}]},{"@type":"WebSite","@id":"https:\/\/learnlearn.uk\/ibcs\/#website","url":"https:\/\/learnlearn.uk\/ibcs\/","name":"IB Computer Science","description":"- learnlearn..uk","publisher":{"@id":"https:\/\/learnlearn.uk\/ibcs\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/learnlearn.uk\/ibcs\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-GB"},{"@type":"Organization","@id":"https:\/\/learnlearn.uk\/ibcs\/#organization","name":"IB Computer Science","url":"https:\/\/learnlearn.uk\/ibcs\/","logo":{"@type":"ImageObject","inLanguage":"en-GB","@id":"https:\/\/learnlearn.uk\/ibcs\/#\/schema\/logo\/image\/","url":"https:\/\/learnlearn.uk\/ibcs\/wp-content\/uploads\/sites\/25\/2022\/09\/LearnLearnLogowhite-300x41.png","contentUrl":"https:\/\/learnlearn.uk\/ibcs\/wp-content\/uploads\/sites\/25\/2022\/09\/LearnLearnLogowhite-300x41.png","width":300,"height":41,"caption":"IB Computer Science"},"image":{"@id":"https:\/\/learnlearn.uk\/ibcs\/#\/schema\/logo\/image\/"}}]}},"rttpg_featured_image_url":null,"rttpg_author":{"display_name":"learnlearnadmin","author_link":"https:\/\/learnlearn.uk\/ibcs\/author\/learnlearnadmin\/"},"rttpg_comment":0,"rttpg_category":null,"rttpg_excerpt":"Why do we use it hexadecimal? Binary is very difficult for humans to read (especially larger numbers) but computers work in binary, so any usage where you need to be able to inspect and edit the binary directly (such as in machine code\/ assembly language) then humans need to be able to read the binary&hellip;&nbsp;Read&hellip;","_links":{"self":[{"href":"https:\/\/learnlearn.uk\/ibcs\/wp-json\/wp\/v2\/pages\/100"}],"collection":[{"href":"https:\/\/learnlearn.uk\/ibcs\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/learnlearn.uk\/ibcs\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/learnlearn.uk\/ibcs\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/learnlearn.uk\/ibcs\/wp-json\/wp\/v2\/comments?post=100"}],"version-history":[{"count":3,"href":"https:\/\/learnlearn.uk\/ibcs\/wp-json\/wp\/v2\/pages\/100\/revisions"}],"predecessor-version":[{"id":104,"href":"https:\/\/learnlearn.uk\/ibcs\/wp-json\/wp\/v2\/pages\/100\/revisions\/104"}],"wp:attachment":[{"href":"https:\/\/learnlearn.uk\/ibcs\/wp-json\/wp\/v2\/media?parent=100"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}