<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>mathematics Archives - SoftUni Global</title>
	<atom:link href="https://softuni.org/tag/mathematics/feed/" rel="self" type="application/rss+xml" />
	<link>https://softuni.org/tag/mathematics/</link>
	<description>Learn Programming and Start a Developer Job</description>
	<lastBuildDate>Thu, 28 Apr 2022 11:27:11 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>

<image>
	<url>https://softuni.org/wp-content/uploads/2022/04/cropped-SoftUni-Global-Logo-Square-notext-32x32.png</url>
	<title>mathematics Archives - SoftUni Global</title>
	<link>https://softuni.org/tag/mathematics/</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Bitwise Operations in Programming [Dev Concepts #34]</title>
		<link>https://softuni.org/dev-concepts/bitwise-operations-in-programming/</link>
					<comments>https://softuni.org/dev-concepts/bitwise-operations-in-programming/#respond</comments>
		
		<dc:creator><![CDATA[Aleksandar Peev]]></dc:creator>
		<pubDate>Wed, 27 Apr 2022 06:00:00 +0000</pubDate>
				<category><![CDATA[Dev Concepts]]></category>
		<category><![CDATA[binary]]></category>
		<category><![CDATA[bit-level]]></category>
		<category><![CDATA[bitmasks]]></category>
		<category><![CDATA[bitwise operations]]></category>
		<category><![CDATA[bitwise operators]]></category>
		<category><![CDATA[devconcepts]]></category>
		<category><![CDATA[mathematics]]></category>
		<category><![CDATA[maths]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[software engineering]]></category>
		<guid isPermaLink="false">https://softuni.org/?p=18889</guid>

					<description><![CDATA[<p>In this lesson you will get an idea of bitwise operations: how they work and why we need them in computer programming. We will explain and demonstrate the main bitwise operators and introduce the concept of bitmasks.</p>
<p>The post <a href="https://softuni.org/dev-concepts/bitwise-operations-in-programming/">Bitwise Operations in Programming [Dev Concepts #34]</a> appeared first on <a href="https://softuni.org">SoftUni Global</a>.</p>
]]></description>
										<content:encoded><![CDATA[		<div data-elementor-type="wp-post" data-elementor-id="18889" class="elementor elementor-18889" data-elementor-post-type="post">
						<section class="elementor-section elementor-top-section elementor-element elementor-element-5d5405e elementor-section-boxed elementor-section-height-default elementor-section-height-default" data-id="5d5405e" data-element_type="section">
						<div class="elementor-container elementor-column-gap-default">
					<div class="elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-0d32134" data-id="0d32134" data-element_type="column">
			<div class="elementor-widget-wrap elementor-element-populated">
						<div class="elementor-element elementor-element-9216798 elementor-widget elementor-widget-text-editor" data-id="9216798" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<p><span data-preserver-spaces="true">In this article, we will also solve several <strong>practical problems</strong> using bitwise operations:<br /></span></p><ul><li><span data-preserver-spaces="true">Get the </span><strong><span data-preserver-spaces="true">last bit </span></strong><span data-preserver-spaces="true">from an integer</span></li><li>Get the <strong style="font-size: 16px;"><span data-preserver-spaces="true">bit at a certain index</span></strong><span style="font-size: 16px;" data-preserver-spaces="true"> from an integer</span></li><li>Change the <strong style="font-size: 16px;"><span data-preserver-spaces="true">bit at a certain index</span></strong><span style="font-size: 16px;" data-preserver-spaces="true"> in an integer</span></li><li>Extract the <strong>bit before the last</strong> from an integer</li></ul><p>If you are not familiar with <strong>bits</strong> and <strong>storing data on the computer</strong> you can read our previous articles about them here:</p><ul><li><a href="https://softuni.org/dev-concepts/what-you-need-to-know-about-bits-bytes-and-kilobytes/">What You Need to Know About Bits, Bytes, and Kilobytes [Dev Concepts #31]</a></li><li><a href="https://softuni.org/dev-concepts/data-representation-in-computer-memory/">Data Representation in Computer Memory [Dev Concepts #33]</a></li></ul>								</div>
				</div>
				<div class="elementor-element elementor-element-88292b4 elementor-widget elementor-widget-video" data-id="88292b4" data-element_type="widget" data-settings="{&quot;youtube_url&quot;:&quot;https:\/\/www.youtube.com\/watch?v=H9U4ylrFVec&quot;,&quot;video_type&quot;:&quot;youtube&quot;,&quot;controls&quot;:&quot;yes&quot;}" data-widget_type="video.default">
				<div class="elementor-widget-container">
							<div class="elementor-wrapper elementor-open-inline">
			<div class="elementor-video"></div>		</div>
						</div>
				</div>
				<div class="elementor-element elementor-element-3d7dddf elementor-widget elementor-widget-text-editor" data-id="3d7dddf" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<h3 style="text-align: center;">Bitwise Operations</h3><p>First, let&#8217;s start with learning about the bitwise operations in programming. They work with the <strong>binary representations</strong> of the numbers, applying <strong><span data-preserver-spaces="true">bit-by-bit</span></strong><strong> calculations</strong>. For example, if we have two <strong>8-bit numbers</strong>, we can apply a bitwise operation, which takes as input the first <strong>8 bits</strong> and the second <strong>8 bits</strong> and produces as a result new <strong>8 bits</strong>.</p>								</div>
				</div>
				<div class="elementor-element elementor-element-6a72260 elementor-widget elementor-widget-text-editor" data-id="6a72260" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<p>A simple bitwise operator over a single argument is the &#8220;<strong>tilde</strong>&#8221; operator – the bitwise logical NOT (also called negation). The operator &#8220;<strong>tilde</strong>&#8221; turns all zeroes to ones and all ones to zeroes, like the &#8220;<strong>exclamation mark</strong>&#8221; operator for the <strong>Boolean expressions</strong>, but it works bit by bit. For example, if we have the <strong>binary number</strong> &#8220;<strong>1 0 0&#8243;</strong>, its negation &#8220;<strong>tilde 1 0 0</strong>&#8221; is &#8220;<strong>0 1 1</strong>&#8220;.</p>								</div>
				</div>
				<div class="elementor-element elementor-element-1a7d81a elementor-widget elementor-widget-image" data-id="1a7d81a" data-element_type="widget" data-widget_type="image.default">
				<div class="elementor-widget-container">
															<img decoding="async" src="https://softuni.org/wp-content/uploads/elementor/thumbs/table-pnol310ovy736u0r6p3vjqkq4wh1e281yd2ynee2hi.png" title="OperatorTable" alt="OperatorTable" loading="lazy" />															</div>
				</div>
				<div class="elementor-element elementor-element-fed9f83 elementor-widget elementor-widget-text-editor" data-id="fed9f83" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<p>The table above illustrates the work of the bitwise <strong>OR</strong>, <strong>AND,</strong> and <strong>XOR</strong> operators.</p><ul><li><span data-preserver-spaces="true">The </span><strong><span data-preserver-spaces="true">bitwise OR operator</span></strong><span data-preserver-spaces="true"> (denoted by the </span><strong><span data-preserver-spaces="true">vertical bar </span></strong><span data-preserver-spaces="true">in most programming languages) returns 1, if </span><strong><span data-preserver-spaces="true">one of its input bits is 1</span></strong><span data-preserver-spaces="true">, otherwise returns 0.</span></li><li><span data-preserver-spaces="true">The </span><strong><span data-preserver-spaces="true">bitwise AND operator</span></strong><span data-preserver-spaces="true"> (denoted by the </span><strong><span data-preserver-spaces="true">ampersand</span></strong><span data-preserver-spaces="true"> in most programming languages) returns 1, if </span><strong><span data-preserver-spaces="true">both of its input bits are 1</span></strong><span data-preserver-spaces="true">, otherwise returns 0.</span></li><li>The <strong style="font-size: 16px;"><span data-preserver-spaces="true">bitwise exclusive OR (XOR) operator</span></strong><span style="font-size: 16px;" data-preserver-spaces="true"> (denoted by the </span><strong style="font-size: 16px;"><span data-preserver-spaces="true">ampersand</span></strong><span style="font-size: 16px;" data-preserver-spaces="true"> in most programming languages) returns 1 if </span><strong style="font-size: 16px;"><span data-preserver-spaces="true">one of its arguments is 1, but not both </span></strong><span style="font-size: 16px;" data-preserver-spaces="true">at the same time, otherwise returns 0.</span></li></ul>								</div>
				</div>
				<div class="elementor-element elementor-element-e92b10b elementor-widget elementor-widget-text-editor" data-id="e92b10b" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<h3 style="text-align: center;">Bit Shifts</h3><p><strong><span data-preserver-spaces="true">Bit shifts</span></strong><span data-preserver-spaces="true"> are bitwise operations, where </span><strong><span data-preserver-spaces="true">bits inside </span></strong><span data-preserver-spaces="true">a number are moved (or shifted) to the left or the right. </span><span data-preserver-spaces="true">During the shifting operation, the bits that fall at invalid positions are lost, and the bits which come from missing positions are </span><strong><span data-preserver-spaces="true">replaced by 0.</span></strong></p>								</div>
				</div>
				<div class="elementor-element elementor-element-4b232c0 elementor-widget elementor-widget-image" data-id="4b232c0" data-element_type="widget" data-widget_type="image.default">
				<div class="elementor-widget-container">
															<img decoding="async" src="https://softuni.org/wp-content/uploads/elementor/thumbs/left-and-right-shift-pnold3ue5zzrobdqc1xva70nfmspx88g08wdw7g3qc.png" title="left-and-right-shift" alt="left-and-right-shift" loading="lazy" />															</div>
				</div>
				<div class="elementor-element elementor-element-f3357d7 elementor-widget elementor-widget-text-editor" data-id="f3357d7" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<p><strong>Bit shifting</strong> can be applied for <b>8-bit</b>, <b>16-bit</b>, <b>32-bit, </b>and <b>64-bit</b> numbers, as well as for numbers of other sizes in bits. The <b>bit size </b>of the number being shifted defines the <b>valid bit positions </b>and where the bits get lost. <strong>Bits</strong> can be shifted by more than<strong> 1</strong> position. For example, <strong>5</strong> shifted left twice is <strong>20</strong> and<strong> 5</strong> shifted right twice is <strong>1</strong>.</p>								</div>
				</div>
				<div class="elementor-element elementor-element-2a0da3f elementor-drop-cap-yes elementor-drop-cap-view-default elementor-widget elementor-widget-text-editor" data-id="2a0da3f" data-element_type="widget" data-settings="{&quot;drop_cap&quot;:&quot;yes&quot;}" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<h3 style="text-align: center;">Why We Need Bitwise Operations?​</h3><p><strong><span data-preserver-spaces="true">Processing bits </span></strong><span data-preserver-spaces="true">is <span style="color: #000000;">important</span> for many fields of computer science, information technologies, and software systems, like </span><strong><span data-preserver-spaces="true">networking protocols</span></strong><span data-preserver-spaces="true">, data storage, and file systems, binary file </span><strong><span data-preserver-spaces="true">formats</span></strong><span data-preserver-spaces="true">, </span><strong><span data-preserver-spaces="true">memory management</span></strong><span data-preserver-spaces="true">, data compression, data encryption, video streaming, Internet of things (IoT) systems, </span><strong><span data-preserver-spaces="true">low-level programming</span></strong><span data-preserver-spaces="true">, computer graphics, and many others.</span></p>								</div>
				</div>
				<div class="elementor-element elementor-element-7b9e6ca elementor-widget elementor-widget-image" data-id="7b9e6ca" data-element_type="widget" data-widget_type="image.default">
				<div class="elementor-widget-container">
															<img decoding="async" src="https://softuni.org/wp-content/uploads/elementor/thumbs/Binary-and-Text-File-pnomvd31vl1gzfdzlcfbsh4uht4vm4v7f3mp9my9ue.png" title="Binary-and-Text-File" alt="Binary-and-Text-File" loading="lazy" />															</div>
				</div>
				<div class="elementor-element elementor-element-b60470c elementor-widget elementor-widget-text-editor" data-id="b60470c" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<p><span data-preserver-spaces="true"><strong>D</strong><b>ata compression </b></span><span data-preserver-spaces="true">algorithms replace bit or byte sequences with shorter bit sequences. For example, the &#8220;<strong>DEFLATE</strong>&#8221; <strong>algorithm</strong>, used to compress data in the </span><strong><span data-preserver-spaces="true">ZIP files</span></strong><span data-preserver-spaces="true">, finds the most often sequences and replaces them with shorter sequences, while it preserves a dictionary between the original bit sequences and their shorter compressed form. This is done using </span><strong><span data-preserver-spaces="true">heavy bit-level</span></strong><span data-preserver-spaces="true"> processing with bitwise operations.</span></p>								</div>
				</div>
				<div class="elementor-element elementor-element-edfdd22 elementor-widget elementor-widget-text-editor" data-id="edfdd22" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<p><span data-preserver-spaces="true">Many <strong>binary file formats</strong> use bits to save space. For example, </span><strong><span data-preserver-spaces="true">PNG</span></strong><span data-preserver-spaces="true"> images (the Portable Network Graphics image format) use <strong>3 bits</strong> to specify the color format used (<strong>8-bit</strong> color, <strong>24-bit</strong> color, <strong>32-bit</strong> color with transparency). These <strong>3 bits</strong> are located at a certain offset in the <strong>PNG image header bytes</strong>, so reading and writing the value encoded in these <strong>3 bits</strong> require bitwise operations.</span></p>								</div>
				</div>
				<div class="elementor-element elementor-element-519abd5 elementor-widget elementor-widget-text-editor" data-id="519abd5" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<p>To sum it up, bitwise operators work with the <strong>binary representations</strong> of the <strong>numbers</strong>, applying<strong> bit-by-bit calculations</strong>. <strong>Bit shifts</strong> are bitwise operations, where bits inside a number are <strong>shifted</strong> to the left or the right. These concepts are an <strong>important aspect of many fields of computer science</strong>.</p>								</div>
				</div>
				<div class="elementor-element elementor-element-4a0f072 elementor-widget elementor-widget-text-editor" data-id="4a0f072" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<h2>Lesson Topics</h2><div><div><div>In this tutorial, we cover the following topics:</div></div><ul><li><p><strong>Bitwise Operations</strong></p></li><li><p><strong>Bitwise Operators &#8211; Examples</strong></p></li><li><p><strong>Bit Shifts</strong></p></li><li><p><strong>Bitwise Operations Problems</strong></p></li><li><p><strong>Why We Need Bitwise Operations?</strong></p></li><li><p><strong>Bit Before the Last &#8211; Problems</strong></p></li></ul></div>								</div>
				</div>
					</div>
		</div>
					</div>
		</section>
				<section class="elementor-section elementor-top-section elementor-element elementor-element-3381a86 elementor-section-boxed elementor-section-height-default elementor-section-height-default" data-id="3381a86" data-element_type="section">
						<div class="elementor-container elementor-column-gap-default">
					<div class="elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-0cf09e3" data-id="0cf09e3" data-element_type="column">
			<div class="elementor-widget-wrap elementor-element-populated">
							</div>
		</div>
					</div>
		</section>
				<section class="elementor-section elementor-top-section elementor-element elementor-element-a0aff0b elementor-section-boxed elementor-section-height-default elementor-section-height-default" data-id="a0aff0b" data-element_type="section">
						<div class="elementor-container elementor-column-gap-default">
					<div class="elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-48c6c18" data-id="48c6c18" data-element_type="column">
			<div class="elementor-widget-wrap elementor-element-populated">
						<div class="elementor-element elementor-element-f972417 elementor-widget elementor-widget-heading" data-id="f972417" data-element_type="widget" data-widget_type="heading.default">
				<div class="elementor-widget-container">
					<h2 class="elementor-heading-title elementor-size-default">Lesson Slides</h2>				</div>
				</div>
				<div class="elementor-element elementor-element-37e6760 elementor-widget elementor-widget-pdfjs_viewer" data-id="37e6760" data-element_type="widget" data-widget_type="pdfjs_viewer.default">
				<div class="elementor-widget-container">
					<iframe src="https://softuni.org/wp-content/plugins/pdf-viewer-for-elementor/assets/pdfjs/web/viewer.html?file=https://softuni.org/wp-content/uploads/2022/04/Dev-Concepts-Episode-34-Bitwise-Operations-in-Programming.pdf&amp;embedded=true" style="display: block; margin-left: auto; margin-right: auto; width: 100%; height: 800px;" frameborder="1" marginheight="0px" marginwidth="0px" allowfullscreen></iframe>				</div>
				</div>
					</div>
		</div>
					</div>
		</section>
				</div>
		<p>The post <a href="https://softuni.org/dev-concepts/bitwise-operations-in-programming/">Bitwise Operations in Programming [Dev Concepts #34]</a> appeared first on <a href="https://softuni.org">SoftUni Global</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://softuni.org/dev-concepts/bitwise-operations-in-programming/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Data Representation in Computer Memory [Dev Concepts #33]</title>
		<link>https://softuni.org/dev-concepts/data-representation-in-computer-memory/</link>
					<comments>https://softuni.org/dev-concepts/data-representation-in-computer-memory/#respond</comments>
		
		<dc:creator><![CDATA[Aleksandar Peev]]></dc:creator>
		<pubDate>Thu, 31 Mar 2022 06:00:00 +0000</pubDate>
				<category><![CDATA[Dev Concepts]]></category>
		<category><![CDATA[binary]]></category>
		<category><![CDATA[binary integers]]></category>
		<category><![CDATA[devconcepts]]></category>
		<category><![CDATA[floating-point]]></category>
		<category><![CDATA[integer range]]></category>
		<category><![CDATA[mathematics]]></category>
		<category><![CDATA[maths]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[signed integers]]></category>
		<category><![CDATA[software engineering]]></category>
		<category><![CDATA[unicode]]></category>
		<guid isPermaLink="false">https://softuni.org/?p=16611</guid>

					<description><![CDATA[<p>In this article of the series Dev Concepts, we take a look at the binary representation of integers, floating-point numbers, text, and unicode.</p>
<p>The post <a href="https://softuni.org/dev-concepts/data-representation-in-computer-memory/">Data Representation in Computer Memory [Dev Concepts #33]</a> appeared first on <a href="https://softuni.org">SoftUni Global</a>.</p>
]]></description>
										<content:encoded><![CDATA[		<div data-elementor-type="wp-post" data-elementor-id="16611" class="elementor elementor-16611" data-elementor-post-type="post">
						<section class="elementor-section elementor-top-section elementor-element elementor-element-5d5405e elementor-section-boxed elementor-section-height-default elementor-section-height-default" data-id="5d5405e" data-element_type="section">
						<div class="elementor-container elementor-column-gap-default">
					<div class="elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-0d32134" data-id="0d32134" data-element_type="column">
			<div class="elementor-widget-wrap elementor-element-populated">
						<div class="elementor-element elementor-element-9216798 elementor-widget elementor-widget-text-editor" data-id="9216798" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<p><span data-preserver-spaces="true">In this lesson, we will talk about <strong>storing data</strong> in the <strong>computer memory</strong>. By the end of this article, you will know how to work with <strong>binary representation</strong> of <strong>integers</strong>, <strong>floating-point numbers</strong>, <strong>text</strong>, and <strong>Unicode</strong>.</span></p>								</div>
				</div>
				<div class="elementor-element elementor-element-88292b4 elementor-widget elementor-widget-video" data-id="88292b4" data-element_type="widget" data-settings="{&quot;youtube_url&quot;:&quot;https:\/\/youtu.be\/rnV88Sg8IU8&quot;,&quot;video_type&quot;:&quot;youtube&quot;,&quot;controls&quot;:&quot;yes&quot;}" data-widget_type="video.default">
				<div class="elementor-widget-container">
							<div class="elementor-wrapper elementor-open-inline">
			<div class="elementor-video"></div>		</div>
						</div>
				</div>
				<div class="elementor-element elementor-element-3d7dddf elementor-widget elementor-widget-text-editor" data-id="3d7dddf" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<p><strong>Integer numbers</strong> are represented in the computer memory, as a <strong>sequence of bits</strong>: 8-bits, 16-bits, 24-bits, 32-bits, 64-bits, and others, but always a multiple of 8 (one byte). They can be <strong>signed</strong> or <strong>unsigned</strong> and depending on this, hold a <strong>positive</strong>, or <strong>negative value</strong>. Some values in the real world can only be <strong>positive</strong> &#8211; the number of students enrolled in a class. There can be also <strong>negative values</strong> in the real world such as daily temperature.</p>								</div>
				</div>
				<div class="elementor-element elementor-element-de70d81 elementor-widget elementor-widget-text-editor" data-id="de70d81" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<p><strong><span data-preserver-spaces="true">Positive 8-bit integers </span></strong><span data-preserver-spaces="true">have a leading <strong>0</strong>, followed by <strong>7</strong> other bits. Their format matches the pattern &#8220;<strong>0XXXXXXX</strong>&#8221; (positive sign +<strong> 7</strong> significant bits). Their value is the decimal value of their significant bits (the last <strong>7 </strong>bits).</span></p><p><span data-preserver-spaces="true"><strong>Negative 8-bit integers</strong> have a leading one, followed by <strong>7</strong> other bits. Their format matches the pattern &#8220;<strong>1YYYYYYY</strong>&#8221; (negative sign + <strong>7</strong> significant bits). Their value is <strong>-128</strong> (which is minus <strong>2</strong> to the power of <strong>7</strong>) plus the decimal value of their significant bits.</span></p><p><img decoding="async" class=" wp-image-16629 aligncenter" src="https://softuni.org/wp-content/uploads/2022/03/8-bit-binary-integer-300x81.png" alt="8-bit-binary-integer" width="345" height="93" srcset="https://softuni.org/wp-content/uploads/2022/03/8-bit-binary-integer-300x81.png 300w, https://softuni.org/wp-content/uploads/2022/03/8-bit-binary-integer-600x163.png 600w, https://softuni.org/wp-content/uploads/2022/03/8-bit-binary-integer.png 616w" sizes="(max-width: 345px) 100vw, 345px" /></p><p style="text-align: center;"><strong>Example of signed 8-bit binary integer</strong></p>								</div>
				</div>
				<div class="elementor-element elementor-element-8569737 elementor-widget elementor-widget-text-editor" data-id="8569737" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<p>The table below summarizes the <strong>ranges of the integer data types</strong> in most popular <strong>programming languages</strong>, which follow the underlying number representations that we discussed in this lesson. Most programming languages also have <strong>64-bit signed</strong> and <strong>unsigned integers</strong>, which behave just like the other integer types but have <strong>significantly larger ranges</strong>.</p><p><img fetchpriority="high" decoding="async" class="wp-image-16639 aligncenter" src="https://softuni.org/wp-content/uploads/2022/03/ranges-of-integer-data-types-300x123.png" alt="ranges-of-integer-data-types" width="541" height="222" srcset="https://softuni.org/wp-content/uploads/2022/03/ranges-of-integer-data-types-300x123.png 300w, https://softuni.org/wp-content/uploads/2022/03/ranges-of-integer-data-types-1024x420.png 1024w, https://softuni.org/wp-content/uploads/2022/03/ranges-of-integer-data-types-768x315.png 768w, https://softuni.org/wp-content/uploads/2022/03/ranges-of-integer-data-types-600x246.png 600w, https://softuni.org/wp-content/uploads/2022/03/ranges-of-integer-data-types.png 1195w" sizes="(max-width: 541px) 100vw, 541px" /></p><ul><li><span data-preserver-spaces="true">The <strong>8-bit</strong> <strong>signed integers</strong> have a range from <strong>-128</strong> to <strong>127</strong>. This is the </span><strong><span data-preserver-spaces="true">sbyte</span></strong><span data-preserver-spaces="true"> type in C# and the byte type in Java.</span></li><li><span data-preserver-spaces="true">The <strong>8-bit unsigned integers</strong> have a range from <strong>0</strong> to <strong>255</strong>. This is the </span><strong><span data-preserver-spaces="true">byte</span></strong><span data-preserver-spaces="true"> type in C#.</span></li><li><span data-preserver-spaces="true">The <strong>16-bit signed integers</strong> have a range from <strong>-32768</strong> to <strong>32767</strong>. This is the </span><strong><span data-preserver-spaces="true">short</span></strong><span data-preserver-spaces="true"> type in Java, C#.</span></li><li><span data-preserver-spaces="true">The <strong>16-bit unsigned integers</strong> have a range from <strong>0</strong> to <strong>65536</strong>. This is the </span><strong><span data-preserver-spaces="true">ushort</span></strong><span data-preserver-spaces="true"> type in C#.</span></li><li><span data-preserver-spaces="true">The <strong>32-bit signed integers</strong> have a range from<strong> -231</strong> … <strong>231-1</strong> (which is from minus <strong>2</strong> billion to <strong>2</strong> billion roughly).  </span><span data-preserver-spaces="true">This is the </span><strong><span data-preserver-spaces="true">int</span></strong><span data-preserver-spaces="true"> type in C#, Java, and most other languages. This </span><strong><span data-preserver-spaces="true">32-bit signed integer </span></strong><span data-preserver-spaces="true">data type is the most often used in computer programming. Most developers write &#8220;<strong>int</strong>&#8221; when they need just a number, without worrying about the range of its possible values because the range of &#8220;</span><strong><span data-preserver-spaces="true">int</span></strong><span data-preserver-spaces="true">&#8221; is large enough for most use cases.</span></li></ul>								</div>
				</div>
				<div class="elementor-element elementor-element-d532f43 elementor-widget elementor-widget-heading" data-id="d532f43" data-element_type="widget" data-widget_type="heading.default">
				<div class="elementor-widget-container">
					<h3 class="elementor-heading-title elementor-size-default">Representing Text</h3>				</div>
				</div>
				<div class="elementor-element elementor-element-edfdd22 elementor-widget elementor-widget-text-editor" data-id="edfdd22" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<p><span data-preserver-spaces="true">Computers represent text characters as unsigned integer numbers, which means that letters are sequences of bits, just like numbers.</span></p><p><span data-preserver-spaces="true">The ASCII standard represents </span><strong><span data-preserver-spaces="true">text characters</span></strong><span data-preserver-spaces="true"> as 8-bit integers. It is one of the oldest standards in the computer industry, which defines mappings between letters and unsigned integers. It simply </span><strong><span data-preserver-spaces="true">assigns a unique number for each letter </span></strong><span data-preserver-spaces="true">and thus allows </span><strong><span data-preserver-spaces="true">letters to be encoded as numbers</span></strong><span data-preserver-spaces="true">.</span></p><p><span data-preserver-spaces="true"><img decoding="async" class=" wp-image-16646 alignleft" src="https://softuni.org/wp-content/uploads/2022/03/representing-text-300x122.png" alt="representing-text" width="274" height="111" srcset="https://softuni.org/wp-content/uploads/2022/03/representing-text-300x122.png 300w, https://softuni.org/wp-content/uploads/2022/03/representing-text.png 555w" sizes="(max-width: 274px) 100vw, 274px" />For example, the letter &#8220;<strong>A</strong>&#8221; has ASCII code </span><strong><span data-preserver-spaces="true">65</span></strong><span data-preserver-spaces="true">. The letter &#8220;<strong>B</strong>&#8221; has ASCII code </span><strong><span data-preserver-spaces="true">66</span></strong><span data-preserver-spaces="true">. The &#8220;</span><strong><span data-preserver-spaces="true">plus sign</span></strong><span data-preserver-spaces="true">&#8221; has ASCII code </span><strong><span data-preserver-spaces="true">43</span></strong><span data-preserver-spaces="true">. The hex and binary values are also shown and are useful in some situations.</span></p>								</div>
				</div>
				<div class="elementor-element elementor-element-3fa755f elementor-widget elementor-widget-heading" data-id="3fa755f" data-element_type="widget" data-widget_type="heading.default">
				<div class="elementor-widget-container">
					<h3 class="elementor-heading-title elementor-size-default">Representing Unicode Text</h3>				</div>
				</div>
				<div class="elementor-element elementor-element-153a75b elementor-widget elementor-widget-text-editor" data-id="153a75b" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<p><span data-preserver-spaces="true">The </span><strong><span data-preserver-spaces="true">Unicode</span></strong><span data-preserver-spaces="true"> standard represents more than </span><strong><span data-preserver-spaces="true">100,000</span></strong><span data-preserver-spaces="true"> text characters as </span><strong><span data-preserver-spaces="true">16-bit integers</span></strong><span data-preserver-spaces="true">. Unlike ASCII it uses </span><strong><span data-preserver-spaces="true">more bits per character </span></strong><span data-preserver-spaces="true">and therefore it can represent texts in many languages and alphabets, like Latin, Cyrillic, Arabic, Chinese, Greek, Korean, Japanese, and many others. </span></p><p>Here are <span data-preserver-spaces="true">a few </span><strong><span data-preserver-spaces="true">examples </span></strong><span data-preserver-spaces="true">of Unicode characters:</span></p><p><span data-preserver-spaces="true"><img loading="lazy" decoding="async" class=" wp-image-16650 alignleft" src="https://softuni.org/wp-content/uploads/2022/03/representing-unicode-text-300x139.png" alt="representing-unicode-text" width="337" height="156" srcset="https://softuni.org/wp-content/uploads/2022/03/representing-unicode-text-300x139.png 300w, https://softuni.org/wp-content/uploads/2022/03/representing-unicode-text.png 595w" sizes="(max-width: 337px) 100vw, 337px" /></span></p><ul><li><span data-preserver-spaces="true">The Latin letter &#8220;<strong>A</strong>&#8221; has Unicode number <strong>65</strong>.</span></li><li><span data-preserver-spaces="true">The Cyrillic letter &#8220;</span><strong><span data-preserver-spaces="true">sht&#8221;</span></strong><span data-preserver-spaces="true"> has Unicode number </span><strong><span data-preserver-spaces="true">1097</span></strong><span data-preserver-spaces="true">.</span></li><li><span data-preserver-spaces="true">The Arabic letter &#8220;</span><strong><span data-preserver-spaces="true">beh&#8221;</span></strong><span data-preserver-spaces="true"> has Unicode number </span><strong><span data-preserver-spaces="true">1576</span></strong><span data-preserver-spaces="true">.</span></li><li><span data-preserver-spaces="true">The &#8220;<strong>guitar</strong>&#8221; emoji symbol has Unicode number <strong>127928</strong>.</span></li></ul>								</div>
				</div>
				<div class="elementor-element elementor-element-e31e9a6 elementor-widget elementor-widget-text-editor" data-id="e31e9a6" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<p><span data-preserver-spaces="true">In any </span><strong><span data-preserver-spaces="true">programming language</span></strong><span data-preserver-spaces="true">, we either </span><strong><span data-preserver-spaces="true">declare data type</span></strong><span data-preserver-spaces="true"> before using a variable, or the language </span><strong><span data-preserver-spaces="true">automatically assigns a specific data type</span></strong><span data-preserver-spaces="true">. In this lesson, we have learned how computers store </span><strong><span data-preserver-spaces="true">integer</span></strong><span data-preserver-spaces="true"> numbers, </span><strong><span data-preserver-spaces="true">floating-point</span></strong><span data-preserver-spaces="true"> numbers, </span><strong><span data-preserver-spaces="true">text</span></strong><span data-preserver-spaces="true">, and other data. These concepts shouldn’t be taken lightly, and be careful with them!</span></p>								</div>
				</div>
				<div class="elementor-element elementor-element-4a0f072 elementor-widget elementor-widget-text-editor" data-id="4a0f072" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
									<h2>Lesson Topics</h2><div><div><div>In this tutorial we cover the following topics:</div></div><ul><li><p><strong>Representation of Data</strong></p></li><li><p><strong>Representing Integers in Memory</strong></p></li><li><p><strong>Representation of Signed Integers</strong></p></li><li><p><strong>Largest and Smallest Signed Integers</strong></p></li><li><p><strong>Integers and Their Ranges in Programming</strong></p></li><li><p><strong>Representing Real Numbers</strong></p></li><li><p><strong>Storing Floating-Point Numbers</strong></p></li><li><p><strong>Representing Text and Unicode Text</strong></p></li><li><p><strong>Sequences of Characters</strong></p></li></ul></div>								</div>
				</div>
					</div>
		</div>
					</div>
		</section>
				<section class="elementor-section elementor-top-section elementor-element elementor-element-3381a86 elementor-section-boxed elementor-section-height-default elementor-section-height-default" data-id="3381a86" data-element_type="section">
						<div class="elementor-container elementor-column-gap-default">
					<div class="elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-0cf09e3" data-id="0cf09e3" data-element_type="column">
			<div class="elementor-widget-wrap elementor-element-populated">
							</div>
		</div>
					</div>
		</section>
				<section class="elementor-section elementor-top-section elementor-element elementor-element-a0aff0b elementor-section-boxed elementor-section-height-default elementor-section-height-default" data-id="a0aff0b" data-element_type="section">
						<div class="elementor-container elementor-column-gap-default">
					<div class="elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-48c6c18" data-id="48c6c18" data-element_type="column">
			<div class="elementor-widget-wrap elementor-element-populated">
						<div class="elementor-element elementor-element-f972417 elementor-widget elementor-widget-heading" data-id="f972417" data-element_type="widget" data-widget_type="heading.default">
				<div class="elementor-widget-container">
					<h2 class="elementor-heading-title elementor-size-default">Lesson Slides</h2>				</div>
				</div>
				<div class="elementor-element elementor-element-37e6760 elementor-widget elementor-widget-pdfjs_viewer" data-id="37e6760" data-element_type="widget" data-widget_type="pdfjs_viewer.default">
				<div class="elementor-widget-container">
					<iframe src="https://softuni.org/wp-content/plugins/pdf-viewer-for-elementor/assets/pdfjs/web/viewer.html?file=https://softuni.org/wp-content/uploads/2022/03/Dev-Concepts-Episode-33-Data-Representation-in-Computer-Memory.pdf&amp;embedded=true" style="display: block; margin-left: auto; margin-right: auto; width: 100%; height: 800px;" frameborder="1" marginheight="0px" marginwidth="0px" allowfullscreen></iframe>				</div>
				</div>
					</div>
		</div>
					</div>
		</section>
				<section class="elementor-section elementor-top-section elementor-element elementor-element-4ca1c1a elementor-section-boxed elementor-section-height-default elementor-section-height-default" data-id="4ca1c1a" data-element_type="section">
						<div class="elementor-container elementor-column-gap-default">
					<div class="elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-bf26fe3" data-id="bf26fe3" data-element_type="column">
			<div class="elementor-widget-wrap">
							</div>
		</div>
					</div>
		</section>
				</div>
		<p>The post <a href="https://softuni.org/dev-concepts/data-representation-in-computer-memory/">Data Representation in Computer Memory [Dev Concepts #33]</a> appeared first on <a href="https://softuni.org">SoftUni Global</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://softuni.org/dev-concepts/data-representation-in-computer-memory/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>

<!--
Performance optimized by W3 Total Cache. Learn more: https://www.boldgrid.com/w3-total-cache/?utm_source=w3tc&utm_medium=footer_comment&utm_campaign=free_plugin

Page Caching using Disk: Enhanced 
Lazy Loading (feed)

Served from: softuni.org @ 2026-04-15 03:28:18 by W3 Total Cache
-->