Saturday, January 25, 2020

Composition of Hydrocarbons

Composition of Hydrocarbons Samerah Mansha Chemistry – Hydrocarbons – Organic compounds are molecules comprising of both carbon and hydrogen atoms. These compounds can be found as gaseous, liquid, or solid. Organic compounds are vital in life processes as they are found in the products we use daily such as soap, cosmetics, perfumes, plastics, rubber, paper, insecticides. The source of energy we use everyday such as petroleum and coal contain organic compounds. Foods such as margarines and flavourings that we taste are the organic compounds interrelating with our taste buds.Scents in perfumes and food that we detect with our nose are organic compounds interrelating with our receptors. The main type of organic compounds are hydrocarbons, which are chemical compounds compromising of carbon and hydrogen atoms. Alkanes and alkenes are two types of hydrocarbons. Alkanes are saturated hydrocarbons due to containing the full amount of hydrogen atoms possible. Alkanes also contain single bonds. The overall formula of an alkane isCnH2n+2, where n shows the quantity of carbon atoms present. The chemical and structural formula of alkanes (see figure 1). Isomers are molecules with an identical chemical formula, but differ in terms of having different structural formula due to varied arrangement of atoms, isomers also have different properties. The isomer of butane C4H10, is 2methyl-propane. (See figure 2) These two compounds are isomers of each other due to having the same chemical formula of C4H10, but vary in terms of having different structural formula. The above propane has an added methyl group, thus called methyl propane. The isomers of hexane C6H14, (see figure 3) The isomers of pentane C5H12, (see figure 4) – A homologous series is simply a group of organic chemical compounds which is ordered in increasing size, such as having similar structures but only differ slightly by a CH2 group within their chain. A series of compounds which are related like alkanes are known as homologous series. This is because alkanes have the same general formulas of CnH2n+2, but differ from the next CH2 unit. All the alkanes in the homologous series have similar chemical properties, but have different physical properties such as boiling point and density increase as the number of carbons atoms increase. Name of Alkane Number Carbon atoms Chemical Formula Simple Structure (Molecular Diagram) Methane 1 C H4 Ethane 2 C2H6 Propane 3 C3H8 Butane 4 C4H10 Pentane 5 C5H12 Hexane 6 C6H14 Heptane 7 C7H16 Octane 8 C8H18 Nonane 9 C9H20 Decane 10 C10H22 Figure: 5 Example of a homologous series of alkanes with structure of CnH2n+2, Ivy Rose, (n.d) 2.4, 2.5 – As alkanes are saturate hydrocarbons, they are deemed unreactive due to containing single bonds such as C-H and C-C bonds which are quiet strong and difficult to break due to the strong intermolecular force. However the only ways alkanes are able to react is via combustion, chlorination and cracking. Combustion is exothermic process and is known burning of carbon compounds, in particular hydrocarbons is a vital source of heat energy. For example by combusting alkanes with oxygen it releases energy which can be instantaneously be used as fuels. In combustion of alkanes such as propane, every single covalent bond within the reactants is broken down and forms a new set of covalent bonds within the products. The balanced formula is: CH3-CH2-CH3 + 5 O2——>3 CO2 + 4 H2O + heat Combustion also producescarbon dioxideand watervapour which is shown above. Another example of combustion of methane: CH4(g) + 2O2(g)→CO2(g) + 2H2O(g) (Methane + Oxygen→Carbon dioxide + Water) If there is not enough oxygen supply within the air, then this would result then would form carbon monoxide gas which is poisons. For example, the below equation shows the partial combustion of methane due to lack of oxygen present: 2CH4(g) + 3O2(g) → 2CO(g)+ 4H2O(g) (Methane + Oxygen → Carbon monoxide + Water) However the burning of alkanes has the potential to cause many enviromental problems, such as the toxic waste gas carbon monoxide and unburnt hydrocarbons which are present in cat emissions. Additional excessive combustion of hydrocarbons increases carbon dioxide emissions which contribute to the greenhouse effect. Another reaction of alkanes is called chlorination which is the when alkanes react with chlorine. For example, when the alkane methane and chlorine react together, the hydrogen atoms of the methane are simply replaced one by one by chlorine atoms. Thus forming a combination of compounds of chloromethane, dichloromethane, trichloromethane and tetrachloromethane. Figure:6 Reaction and products that occur between methane and chlorine, Chem Guide, (2000) Some fuels which are made from oil mixtures contain large hydrocarbon molecules which are not useful, as they do not flow easily and are quiet difficult to ignite. This is when the process of the cracking, a thermal decompositionreaction comes in. The process of cracking allows big hydrocarbon molecules to be broken down into much smaller and more useful hydrocarbon molecules. This is achieved by the large hydrocarbon molecules being vaporised and put in a hot catalyst which breakdowns the chemical bonds within molecules thus forming smaller hydrocarbon molecules. For example in the cracking process of the alkane hexane, a smaller alkane is formed plus an alkene. The alkene is formed because the alkane which is this case is the hexane does not contain enough hydrogen atoms in order to produce another alkane. . C6H14 C4H10 + C2H4 Figure: 7 The cracking reaction of the alkane hexane, BBC Bitesize, (n.d) 3.1 Alkenes are also hydrocarbons compromising of carbon and hydrogen atoms, but also have one or more double bonds present within the carbon chain. Alkenes are also a series of compounds within a homologous series but have a different general formula of CnH2n. Examples of alkenes and their chemical and structural formula (See figure 8) Geometrical isomerisms are formed when atoms or groups of molecules are arranged in a different way due to limited amount of rotation of the bond or bonds within a molecule. For example, there are two geometrical isomers for the alkene 2-butene, as there are two different spatial arrangements of methyl groups and double bond, thus forming geometrical isomers called cis-2-butene and trans-2-butene, these are formed because the CH3 groups are found on opposite of the double bond. (See figure 9) Another example is the 1,2-dichloroethene, forms the trans-1,2 dichoethne and Cis-1,2 dichroloethee gemotical isomers, (See figure 10) One of the isomer, the two chlorine atoms are locked upon opposite sides of double bond, thus called theTransisomer whereas in the other isomer the two chlorine atoms are locked within the same side of the double bond thus known as cisisomer. (See figure 10). 3.2, 3.3 – A single covalent bond is simply when one pair of electrons (2 electrons) are shared amongst two atoms. It typically consists of one sigma bond. On the other hand, bonds with more than one mutual pair of electrons are called multiple bonds, in particular sharing two pairs of electrons is called a double bond where 4 electrons are covalently bonded together, the double bonds typically comprises of one sigma and one pi bond. Alkanes are saturated compounds with single covalent sigma bonds, thus are more stable than alkenes as high amount of energy would be needed to break these. Alkenes are unsaturated with the presence of carbon-carbon pi-bonds and sigma bonds which connects to carbon atoms which makes them highly more reactive than alkanes due to the existence of double bonds and because they are unstable as they want to achieve full saturation. Another reason alkenes are ore reactive is because in double bond there is a lone pair of free electrons which is easily lost thus highly reactive as its easily lost in order to be covalently single bonded Thus when alkenes react in such reactions such as combustion or additions, it mainly involves the rupture of the pi bond, thus forming newsingle bonds. Within the alkenes, the double bond allows more electrons to be put into the joining within the two carbon atoms, thus held less strongly making them more likely to react with less input of energy needed to ov ercome the activation energy of reaction 3.4, 3.5 The main reaction of alkenes is the addition reaction which occurs due to the extra electron found within the C=C double bond which causes alkenes to be attacked by species called electrophiles in which â€Å"like† positve charged electrons. Due to the electrophile having an positive charge it is attracted towards the alkene which causes the electrons within the pi bond to break, then electrons from it are used in order to form a bond to the positive end joining the two carbon atoms to other things. Figure: 11 Example of an addition reaction using X-Y, Chem guide, (2003) Another example of addition reactions is hydrogen and hydrogen chloride. ethene +hydrogen→ethane = C2H4+H2→C2H6 Due to alkenes containing pi-bonds (double or triple) which can be broken easily due to their overlay, it makes them the prime target for addition reaction, which stabilises the molecular orbitals by forming sigma-bonds, which are stronger. Another example ofan addition reactionis the bromine test which is simply used in order to tell the difference between an alkane and an alkene. Alkenes undergo an addition reaction when combined with bromine water which is usually orangey-brown in colour, but when it is shaken with an alkene, the solution becomes colourless as alkene decolourise bromine water as it reacts with the double bond, which indicates the presence of a pi bond. However if bromine water was shaken with an alkane, the bromine water remains brown as there is no double bond present For example, the bromine is decolourised because a colourless dibromethane compound forms. For example: ethene + bromine → dibromoethane C2H4+ Br2→ C2H4Br2 (See figure 12) 3.6 Polymerisation is an important reaction of alkenes. During polymerisation all the atoms within the alkenes are used to form a polymer, a polymer is a large long-chain of molecule of repeated units which formed when smaller molecule called monomers join together. For example, several chloroethene monomers join end-to-end to make poly(chloroethene), which is also known as PVC via the polymerisation process. (See figure 13) Figure: 14 Addition polymerisation reaction, BBC Bitesize, (n.d) Alkenes act as monomer due to the presence of the double bond. Different polymers have different properties, so they have different uses which make them important in everyday life. For example, the polymer polyethene is commonly used to make plastic bags and bottles, whereas polyproper is used to make crated and ropes and polycholorethene is uses in water pipes and commonly in insulation of electricity cables. However regardless of the uses of polymers being useful their disposal creates various problems, due to being non-biodegradable, because being unreactive to majority of chemicals and bacteria. However can only be recycled, but this is a costly process. They can also be burnt which does produce energy but again produces toxic fumes. References: Accelerated Study Notes, (n.d), Alkenes, [on-line], Available at: http://www.acceleratedstudynotes.com/ib/chemistry-ib/ib-chemistry-alkenes/, [Accessed on 16/05/15]. Barry Gray, (2006), Organic Chemistry and the Alkanes, Alkenes and Alkynes, [on-line], Available at: http://www.barrygray.pwp.blueyonder.co.uk/Tutoring/OrgC.html, [Accessed on 18/05/15]. BBC Bitesize, (n.d), Alkanes, [on-line], Available at: http://www.bbc.co.uk/schools/gcsebitesize/science/aqa/crudeoil/crudeoilrev1.shtml, [Accessed on 16/05/15]. BBC Bitesize, (n.d), Polymerisation, [on-line], Available at: http://www.bbc.co.uk/schools/gcsebitesize/science/21c_pre_2011/materials/chemicalscrudeoilrev3.shtml, [Accessed on 11/06/15]. BBC Bitesize, (n.d), Polymers and ethanol from oil – Cracking, [on-line], Available at: http://www.bbc.co.uk/schools/gcsebitesize/science/aqa_pre_2011/oils/polymersrev1.shtml, [Accessed on 16/05/15]. BBC Bitesize, (n.d), Polymers and ethanol, [on-line], Available at: http://www.bbc.co.uk/schools/gcsebitesize/science/aqa/substancesfromcrudeoil/polymersandethanolrev1.shtml, [Accessed on 14/06/15]. BBC Bitesize, (n.d), Properties of Alkanes, [on-line], Available at: http://www.bbc.co.uk/bitesize/standard/chemistry/materialsfromoil/hydrocarbons/revision/3/, Accessed on 15/06/15]. Boundless, (n.d), Reactions of alkenes and alkynes, [on-line], Available at: https://www.boundless.com/chemistry/textbooks/boundless-chemistry-textbook/organic-chemistry-23/alkenes-and-alkynes-164/reactions-of-alkenes-and-alkynes-633-3626/, [Accessed on 15/06/15]. Chem Guide, (2000), Multiple substitutions in the methane and chlorine reaction, [on-line], Available at: http://www.chemguide.co.uk/mechanisms/freerad/multisubcl.html, [Accessed on 18/05/15]. Chem Guide, (2003), Introducing Alkenes, [on-line], Available at: http://www.chemguide.co.uk/organicprops/alkenes/background.html, [Accessed on 15/05/15]. Chem guide, (2012), Structural Isomerism, [on-line], Available at: http://www.chemguide.co.uk/basicorg/isomerism/structural.html, [Accessed on 12/05/15]. Chem Guide, (n.d), The halogenation of alkanes, [on-line], Available at: http://www.chemguide.co.uk/organicprops/alkanes/halogenation.html, [Accessed on 16/05/15]. Chem Wiki, (n.d), Cis Trans Isomers of Alkanes, [on-line], Available at: http://chemwiki.ucdavis.edu/Organic_Chemistry/Fundamentals/Structure_of_Organic_Molecules/Cis_and_Trans_Isomers_of_Alkanes, [Accessed on 14/05/15]. Chem Wiki, (n.d), Geometric Isomerism in Organic Molecules, [on-line], Available at:http://chemwiki.ucdavis.edu/Organic_Chemistry/Fundamentals/Isomerism_in_Organic_Compounds/Geometric_Isomerism_in_Organic_Molecules, [Accessed on 14/05/15]. Chemistry Msu,(2013), Reactions of Alkenes, [on-line], Available at: http://www2.chemistry.msu.edu/faculty/reusch/VirtTxtJml/addene1.htm, [Accessed on 15/05/15]. Cliffs Notes, (n.d), Alkenes: Molecular and Structural Formulas, [on-line], Available at: http://www.cliffsnotes.com/sciences/chemistry/organic-chemistry-i/structure-and-properties-of-alkenes/alkenes-molecular-and-structural-formulas, [Accessed on 16/06/15]. Ivy Rose, (n.d), Homologous Series, [on-line], Available at: http://www.ivyroses.com/Chemistry/Organic/Homologous-Series.php, [Accessed on 17/05/15]. Organic Chemistry Blog,(2012), Organic chemistry in everyday life, [on-line], Available at: http://organicchemistryucsi.blogspot.co.uk/, [Accessed on 16/05/15]. Organic Chemistry, (n.d), Polymerisation of Alkenes, [on-line], Available at: http://www.organicchemistry.com/polymerization-of-alkenes/, [Accessed o 15/05/15].

Friday, January 17, 2020

Buss1 Key Terms

BUSS 2 Key Term Definitions  ©T Ockenden Finance: Budget – A budget is regarded as a goal or a â€Å"yardstick†; it’s something a business uses in order to work to, for example: a firm may have budgeted fixed costs of ? 5000, they aim to either meet this budget or fall below it to operate to the desired level. Variance – Variance applies to budgets, and it is the difference between the forecasted or budgeted figure, and the actual figure that comes out at the end of a certain review period.Cash flow forecast – A cash flow forecast is a document that records the expected inflows and outflows of a business. Overdraft – Short term borrowing from a bank, a business will only take out as much money as it needs in order to cover its daily cash shortfall, because overdrafts are high interest short term finance options and can be required to pay back within 24 hours. Factoring – Fully named debt factoring, is the process by which the debt fa ctor company buys a percentage of the debt owed to one company by another company or customer (often around 80%).This means although the company owed to will lose 20% of the money, it means that 80% can be with them immediately rather than having to chase for it. Sale and leaseback – This is where a company will sell an asset off in order to generate short term finance, but they will buy back the asset on a lease basis as in the will pay for it as and when they need it. Net profit margin – Simply a profit margin is the gap between the prices the unit is sold for and how much it costs to produce it. Net profit margin is worked out by doing net profit over sales turnover x100.Return on capital – Profit as a percentage of the capital invested in a project. Profitability – Profitability measures profit against another variable in the business, for example you’ve got net profit margin which is profit in relation to costs, or ROC, which is profit in rela tion to the capital invested. Marketing: Niche marketing – Niche marketing is where a business is tailoring a product or service to a very specific customer or market (think cooking dinner for the queen), requires much research in to their needs and wants and other factors in order to get it right.Mass marketing – Mass marketing is almost completely the opposite, it involves creating a product or service with mass appeal and promoting it to all types of consumers (bread and other commodities). Business to business marketing – This is a term to describe the transactions that take place between one company and another, in this sense the customer is seen as another business. Consumer marketing – When a company sells its products and services to the individual consumer, it is referred to in marketing-speak as B2C, or business-to-consumer.Marketing mix – This refers to the 4 main ingredients in the marketing cake, product, price, place and promotion. Al though is BUSS 2 they ask you specific stuff on each section. USP – One feature that makes a product or service different from all its rivals, for example the apple operating system on iphone. Product differentiation – The extent to which your product or brand is differentiated is the amount to which customers feel your product or brand is different from others in the same market.Product life cycle – This is sort of like the â€Å"this is your life† book for a product, it comprises of stages; Introduction, growth, maturity, saturation and decline. Represented as a graph in most cases. Product portfolio – Product portfolio analysis looks at the existing position of a company’s products. The best way is Boston matrix here; a firm can place their product in any of the four boxes and from there, decide if a new product needs to be launched or increased promotion is needed or even an introduction to a new market.Boston matrix – The Boston matrix shows the market share of each of the firm’s products and the rate of growth of the markets each product is in; helps in the decision making process of new products or more promotion/new market e. t. c. Promotional mix – The combination of promotional methods used by a business when marketing its products. PR – This is an attempt to affect a consumer’s opinion of a product without actually spending on media advertising, it can involve getting journalists to mention the product in regular publications such as newspapers and T. V magazines.Branding – Branding is the overall image that is tagged to everything a company does, it’s the thought consumers have when they see the company logo, for example, when people see the M&S sign, they automatically think high quality. Merchandising – This requires employees to visit shops where the company’s product is sold to ensure that the brand’s display looks eye-catching and ti dy. An example is the dump bin displays you sometimes see at the end of shopping aisles when a new product is launched. Sales promotions – These range from little competitions you see on the actual product packaging to offers run by the shop itself such as BOGOF’s.Direct selling – This is where potential customers are approached directly. This used to be door to door sales type people, but increasingly more know it involves the use of tele sales. Advertising – Advertising is a form of promotion; there are various methods firms use, such as: T. V adverts, radio ads, billboards around town, leaflets given out in the street e. t. c. It’s the way firms get the knowledge that their product is around out there. Pricing strategies – A pricing strategy is a company’s plan for setting its prices for products over the medium to long term. Short term offers are known as tactics.Tactics can however make strategies or help them. Price skimming â⠂¬â€œ Skimming involves pricing a new product quite highly, it is used when the product is innovative (Apple), as the product is new there is no competition. Price penetration – This involves pricing a new product at a fairly low price in order to achieve high sales volume. It’s used when launching a product into a market where there are similar products; the price is set lower to gain market share. Price leader – This is where the price is set above the market level. This is possible when the company has strong branding or there is little threat from competitors.Price taker – This is when the price is set at the market level or at a discount to the market. This usually happens in highly saturated and competitive markets or in a market where one company dominates. Pricing tactics – Whichever strategy has been chosen, there are tactics that also need to be considered. They can be part of normal pricing or used as an element in the firm’s prom otional tactics. Loss leaders – Prices are set purposefully low – so low that the firm may make a loss on the product; the idea is that purchasing these products will encourage the customer to buy complimentary products to generate profit.Usually common in supermarket environments. Psychological pricing – Prices are set at a level that seems as if it I lower to the customer i. e. 9. 99 as opposed to 10. 50. Price elasticity – A measurement of the extent to which a product’s demand changes when its price is changed. Distribution channel – Distribution channels are the ways in which products get to consumers in the right place for them to purchase them. Oligopoly – A market in which a few large companies have dominant share, for example: the UK chocolate market a 70% share split between Cadbury, Nestle and Mars.Competitive markets – Could be described as a market where there is intense rivalry between producers of a similar good or service. Competitiveness – Measures a firm’s ability to compete (compares its consumer offer to the offers made by rivals). People: Organisational structure – Organisational structure is the formal and ordered way the management of a business is organised. When displayed in the familiar diagram format, it shows the departments or functions within the business and who is answerable to whom.Levels of hierarchy – These show the number of different supervisory and management levels between the bottom of the diagram and the top of the hierarchy. Span of control – This term describes the number of people directly under the supervision of a manager. Chain of command – This is to do with communication, and shows the reporting system from the top of the hierarchy to the bottom (the route info takes through the business). Delegation – Handing power down the hierarchy to junior managers or workers. Labour productivity – Purely and simp ly, the output per person (Output over no. Of staff).One of the ways to measure workforce effectiveness. Labour turnover – The rate at which people leave their jobs and need to be replaced. The other way to measure workforce effectiveness. Recruitment – Recruitment is the process of filling job vacancies when they arise within a firm. Selection – the process of choosing from a field of applicants from a job Selection techniques – The processes used by a company to choose the most appropriate person for a job, examples are interviews and trial runs. Internal recruitment – Where a job vacancy is filled by using someone who already works within the company.Sometimes seen as promotion. External recruitment – Where a job vacancy is filled by using someone who comes from outside the company. Assessment centre – These allow for more detailed analysis of person’s suitability for a role by subjecting them to realistic simulations, often over a number of days. Types of selection test – A number of selection techniques exist, including: Interviews, testing and profiling (aptitude tests) and assessment centres. Person specification – A document that details the qualifications, skills and other personal qualities required in order to carry out the advertised job.It describes the ideal person Job description – Not the same as a person spec, a document that outlines the duties and responsibilities associated with an advertised vacancy. It describes the job On the job training – Where employees acquire or develop the skills they need without leaving their usual work place (shadowing of higher level employees). Off the job training – Where employees leave their usual workplace in order to receive instruction on how to perform their job role well (College or university) Job enrichment – Herzberg: â€Å"giving people the opportunity to use their ability†.Job enlargement †“ General term for anything that increases the scope of a job. (Job rotation, job loading and job enrichment). Empowerment – A management practice of sharing information, rewards, and power with employees so that they can take initiative and make decisions to solve problems and improve service and performance. Team-working – Individuals work in groups rather than being given highly specialised, individual jobs. Operations Management: Operational targets – Operational targets or objectives are the specific, detailed production targets set by a company to ensure that its overall company goals are achieved.Unit costs – The cost of one unit of output is a raw measure of the efficiency of a firm’s operations (total cost over total output = unit cost). Quality – Quality or specifically quality management, means providing what the customer wants at the right time, with the right level of quality and consistency and therefore yielding high custome r satisfaction. Capacity utilisation – Actual output as a proportion of maximum capacity (out of 100%). Non-standard orders – Sometimes a company will be approached by customers with special orders at a different price to their regular selling price.A customer with special requirements may require changes to the product or a modified design, but they may be willing to pay a much higher price. Overtime – Paying staff extra to work longer hours than their contracts state. Temporary staff – Employees on fixed-term contacts of employment, either for a determined amount of time or until a specific task has been completed. Part-time staff – Staff who are contacted to work for anything less than what is considered the basic full-time hours of the business.Rationalisation – Reorganising in order to increase efficiency. This often implies cutting capacity to increase the percentage utilisation. Sub-contracting – Where another business is used to perform or supply certain aspects of a firm’s operations (outsourcing). Quality control – Quality control is the traditional way to manage quality, and is based on inspection after a certain batch number of units. Quality assurance – Quality is a system that assures customers that detailed systems are in place to govern quality at every stage of production.TQM (total quality management) – This was introduced by an American business man W. Edwards Deming in early 1980s. TQM is not a management tool, it is a philosophy. It is a way of looking at quality issues at every aspect of the business (think kaizen stuff). Quality standards – Companies can apply for quality standards certification to show the rest of their market and others that they are serious about the quality of what they do. ISO 9000 certification covers customer service in firms where the skill is relevant.Customer service – Describes the range of actions taken by a business wh en interacting with customers. Effective CS will meet or exceed the expectation that customers have of the business. Suppliers – A person or business that serves as a source for goods and services. For example, Sysco Corporation is a major supplier to the food service industry. Robotics – Robotics are the automated systems used on many of today’s modern mass production lines (car manufacturers). They are programmed to do the same thing over and over, so repetitive tasks can be completed with 100% efficiency.Automation – Typically refers to automated stock control systems, they are based on laser scanning or bar-coded info. This ensures the computer knows the exact quantity of each product that has come into the stockroom. Equally when something is sold the number is subtracted from the original stock room total. Communication technology – This covers aspects all over the business, we’ve got communication with customers; two main ways compani es can electronically communicate with customers: 1 is a website and 2 is a database management system that holds information on all of a firm’s customers.Also you’ve got communication with suppliers, with things such as electronic data interchange, this links up data sources between branches of a business this can be useful to find out instantly how much stock is in a store on the other side of the country. Design technology – Computer Aided Design (CAD) has been around for over 20 years but is now much more affordable and very useful. CAD can show 3D versions of a drawing to see what it would look like if it was a 3D model. Productivity – Output per person (a measure of efficiency).

Thursday, January 9, 2020

A Beginner Guide to Comparing Values in Perl

Perl  comparison operators can sometimes be confusing to new Perl programmers. The confusion stems from the fact that  Perl  actually has two sets of comparison operators - one for comparing numeric values and one for comparing string American Standard Code for Information Interchange (ASCII) values.   Since  comparison operators  are typically used to control logical program flow and make important decisions, using the wrong operator for the value you are testing can lead to bizarre errors and hours of debugging, if youre not careful. Dont forget to catch whats written at the very bottom of this page for some last-minute things to remember. Equal, Not Equal The simplest and probably most used comparison operators test to see if one value is equal to another value. If the values are equal, the test returns true, and if the values are not equal, the test returns false. For testing the equality of two numeric values, we use the comparison operator . For testing the equality of two string values, we use the comparison operator eq (EQual). Heres an example of both: if (5 5) { print for numeric values\n; } if (moe eq moe) { print eq (EQual) for string values\n; } Testing for the opposite, not equal, is very similar. Remember that this test will return true if the values tested are not equal to each other. To see if two numeric values are not equal to each other, we use the comparison operator !. To see if two string values are not equal to each other, we use the comparison operator ne (Not Equal). if (5 ! 6) { print ! for numeric values\n; } if (moe ne curly) { print ne (Not Equal) for string values\n; } Greater Than, Greater Than or Equal To Now lets look at the  greater than  comparison operators. Using this first operator, you can test to see if one value is  greater than  another value. To see if two  numeric  values are  greater than  each other, we use the comparison operator  . To see if two  string  values are  greater than  each other, we use the comparison operator  gt  (Greater Than). if (5 4) { print for numeric values\n; } if (B gt A) { print gt (Greater Than) for string values\n; } You can also test for  greater than or equal to, which looks very similar. Keep in mind that this test will return  true  if the values tested are equal to each other, or if the value on the left is greater than the value on the right. To see if two  numeric  values are  greater than or equal to  each other, we use the comparison operator  . To see if two  string  values are  greater than or equal to  each other, we use the comparison operator  ge  (Greater-than Equal-to). if (5 5) { print for numeric values\n; } if (B ge A) { print ge (Greater-than Equal-to) for string values\n; } Less Than, Less Than or Equal To There are a variety of comparison operators you can use to determine the logical flow of your  Perl programs. Weve already discussed the difference between the Perl numeric comparison operators and the Perl string comparison operators, which can cause some confusion to  new Perl programmers.  Weve also learned how to tell if two values are equal to, or not equal to each other, and weve learned how to tell if two values are greater than or equal to each other. Lets look at the  less than  comparison operators. Using this first operator, you can test to see if one value is  less than  another value. To see if two  numeric  values are  less than  each other, we use the comparison operator  . To see if two  string  values are  less than  each other, we use the comparison operator  lt  (Less Than). if (4 5) { print for numeric values\n; } if (A lt B) { print lt (Less Than) for string values\n; } You can also test for,  less than or equal to, which looks very similar. Remember that this test will return  true  if the values tested are equal to each other, or if the value on the left is less than the value on the right. To see if two  numeric  values are  less than or equal to  each other, we use the comparison operator  . To see if two  string  values are  less than or equal to  each other, we use the comparison operator  le  (Less-than Equal-to). if (5 5) { print for numeric values\n; } if (A le B) { print le (Less-than Equal-to) for string values\n; } More Information on Comparison Operators When we talk about string values being equal to each other, were referring to their ASCII values. So, the capital letters are technically less than the lowercase letters, and the higher the letter is in the alphabet, the higher the ASCII value. Make sure you check your  ASCII values  if youre trying to make logical decisions based on strings.

Wednesday, January 1, 2020

Global Warming Is Not Real Or Happening - 1515 Words

Extensive research from various scientists indicate that, from carbon emissions and several other factors, global warming does exist. Countries throughout the world have been putting their efforts into research surrounding this topic to see if it is an actual problem. Globally, all of the top ten warmest years have happened since 1998 (NOAA, 2015). One of the most confused claims from citizens is that â€Å"It is cold outside, therefore global warming is not real or happening.† But, just because the temperature of one area is below normal does not mean the average temperature of the Earth is rising. Many scientists and officials claim that the Earth is being warmed more and more each day, while others claim the Earth is going through a period of above average temperatures, as is has many times before. Evidence can sway uneducated citizens towards the facts of global warming or the â€Å"hoax.† The rise in carbon emissions and average temperature of the entire Ear th cannot be ignored. But, many say that this is just a periodical rise in climate temperatures. Others say that there is no warming and the evidence is fake or a hoax. But, after all positions are taken, global warming is a serious issue that needs attention. Global warming is a serious issue that could have many serious problems if it is not put to rest. One of the main problems is the rising sea level. Around the world one highly sought after commodity is beach front real estate. It is highly expensiveShow MoreRelatedThe Issue Of Global Warming1504 Words   |  7 Pagesaffecting you all. It’s about global warming. This issue will more than likely take away from everyone in the end, or at least humanity’s efforts to be a greater civilization, if you don’t take care of it. My question is, why aren’t you? For billions of years your Earth withstood countless hardships and has since lived among the cosmos, but now it’s going to be intoxicated and fall ill in a manner of hundreds of years, because of you? Global warming is the issue of the earth warming up due to man’s technologicalRead MoreGlobal Warming - Is It Man-Made or Mother Nature or Both?1305 Words   |  6 PagesGlobal Warming - Is It Man-Made or Mother Nature or Both? Global warming is define as the global increase in the average temperature of the earth, that near the air-surface and the oceans which caused by the emission of the gases. These include carbon dioxide, methane and nitrogen that trap the sun’s heat in the earth. It’s happened since the mid-twentieth century and its projected would be continuation. Global warming is an extremely severe problem facing the world today. Its effects and causesRead MoreGlobal Warming Is A Problem1654 Words   |  7 Pagesthis reason is global warming. Global warming is a problem that some people choose to ignore. They claim it does not exist. Global warming is real. It is time for people to stop ignoring it and start searching for a solution. Although many people do not believe in global warming, blaming the climate change on the sun, global warming is a serious danger to the Earth because it could have serious effects on the plant and animal populations. To fully grasp the effects of global warming, one must firstRead MoreIs Global Warming Real or Not?766 Words   |  3 Pages Is Global Warming Real or Not? 70% of people in the world think that global warming is real and 12% say its not happening at all. Well to you non-believers did you ever wonder way places that were beautiful arent so beautiful now? For example the Arctic a winter wonderland now big, huge, super deep, pool almost gone. Its happening everywhere and it affects everything and everyone. There are tons of thoughts on Global Warming(G.W) on if its happening or not. Not many people believe in climateRead MoreGlobal Warming : Is The Planet Earth Just Going Through A Natural Warming?866 Words   |  4 PagesBautista Global warming a real or is the planet Earth just going through a natural warming, and cooling cycles? There are a number of people that believe global warming does not exists, that the planet Earth goes through changes of warm and cool temperatures, every ninety to hundred years. But, there is also a bigger number of people saying that this is not true, and the changes of warm temperatures that are happening now, and the changes of the last thirty years are due to a global warming, done byRead MoreClimate Change : Global Warming890 Words   |  4 Pages Global climate has been changing throughout history; just in the last 650,000 years there have been seven cycles of glacial advances and retreats. The abrupt end of the last ice age, about 7,000 years ago, marked the beginning of the modern climate era and of human civilization. Global warming has gradually increased the overall temperature of the earth’s atmosphere generally attributed to the greenhouse effect caused by increased levels of carbon dioxide, chlorofluorocarbons, and other pollutantsRead MoreThe Reality Of Climate Change1579 Words   |  7 Pageschange is real; in fact, it s very real. Most people like to decipher the fact that global warming is nothing more than just a perpetuate myth, but if the recent weather especially in the state of New Jersey hasn t told you anything, the weather can be extremely bipolar at times. One day it s sixty degrees Fahrenheit, and the day after its thirty degrees with heavy snow crashing to the ground below. There are several different reasons out there that help describe the fact that global warmingRead MoreGlobal Warming And Its Effects On The Environment Essay1516 Words   |  7 PagesSome people say global warming is caused by human activity, others say global warming doesn’t even exist. Some people claim that the climate is changing for the worse. They believe that humans are the primary cause of these changes, especially the increase in temperature, caused by the burning of fossil fuels. They believe that the temperature changes are causing glaciers to melt. They claim that the melting of ice masses leads to a higher sea level and worsening conditions for Arctic animals, asRead MoreGlobal Warming : An Inconvenient Truth Essay1200 Words   |  5 Pages Global warming is defined as the process of gradual growth of average annual temperature of the atmosphere, the Earth, and the oceans. Global warming and climate change threaten the very existence of earths inhabitants. In 2006, former senator Al Gore created an amazing award winning documentary on global warming named â€Å"An Inconvenient Truth†. Yet there are still skeptics that can t decide on whether global warming is actually facts or a theory. People need to wake up and realize that this is realRead MoreGlobal Warming: Fiction or Truth? Essay example1369 Words   |  6 PagesTrue or false; global warming is a catastrophic event that is occurring by natural and human means that is causing global temperature to rise and that can lead to many disasters? This has been an issue that hundreds and maybe thousands of scientists and citizens have debated about back and forth. The thought of global warming existing is a strong claim that many and most people have been backing up . Reliable sources have claims and evidence that is sufficient to prove global warming but other reliable