Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Tamilnadu State Board New Syllabus Samacheer Kalvi 12th Computer Applications Guide Pdf Chapter 17 E-Commerce Security Systems Text Book Back Questions and Answers, Notes.

Tamilnadu Samacheer Kalvi 12th Computer Applications Solutions Chapter 17 E-Commerce Security Systems

12th Computer Applications Guide E-Commerce Security Systems Text Book Questions and Answers

Part I

Choose The Correct Answers

Question 1.
In E-Commerce, when a stolen credit card is used to make a purchase it is termed as
a) Friendly fraud
b) Clean fraud
c) Triangulation fraud
d) Cyber squatting
Answer:
b) Clean fraud

Question 2.
Which of the following is not a security element involved in E-Commerce?
a) Authenticity
b) Confidentiality
c) Fishing
d) Privacy
Answer:
c) Fishing

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 3.
Asymmetric encryption is also called as
a) Secure Electronic Transaction
b) Certification Authority
c) RSA algorithm
d) Payment Information
Answer:
c) RSA algorithm

Question 4.
The security authentication technology does not include
i) Digital Signatures
ii) Digital Time Stamps
iii) Digital Technology
iv) Digital Certificates

a) i, ii & iv
b) ii & iii
c) i, ii & iii
d) all the above
Answer:
b) ii & iii

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 5.
PGP stands for
a) Pretty Good Privacy
b) Pretty Good Person
c) Private Good Privacy
d) Private Good Person
Answer:
a) Pretty Good Privacy

Question 6.
…………….. protocol is used for securing credit cards transactions via the Internet
a) Secure Electronic Transaction (SET)
b) Credit Card Verification
c) Symmetric Key Encryption
d) Public Key Encryption
Answer:
a) Secure Electronic Transaction (SET)

Question 7.
Secure Electronic Transaction (SET) was developed in
a) 1999
b) 1996
c) 1969
d) 1997
Answer:
b) 1996

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 8.
The websites secured by Secure Socket Layer protocols can be identified using
a) html://
b) http://
c) htmls://
d) https://
Answer:
d) https://

Question 9.
3-D Secure, a protocol was developed by
a) Visa
b) Master
c) Rupay
d) PayTM
Answer:
b) Master

Question 10.
Which of the following is true about Ransomware
a) Ransomware is not a subset of malware
b) Ransomware deletes the file instantly
c) Typo piracy is a form of ransomware
d) Hackers demand ransom from the victim
Answer:
d) Hackers demand ransom from the victim

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Part II

Short Answers

Question 1.
Write about information leakage in E-Commerce.
Answer:
Information leakage:
The leakage of trade secrets in E-Commerce mainly includes two aspects:

  1. The content of the transaction between the vendor and customer is stolen by the third party;
  2. The documents provided by the merchant to the customer or vice versa are illegally used by another.
  3. This intercepting and stealing of online documents is called information leakage.

Question 2.
Write a short note on typo piracy.
Answer:

  • Typopiracy ¡s a variant of Cyber Squatting.
  • Some fake websites try to take advantage of users’ common typographical errors in typing a websíte address and direct users to a different website.
  • Such people try to take advantage of some popular websites to generate accidental traffic for their websites.

Examples:

  • www.goggle.com,
  • www.facebook.com

Question 3.
Define non-repudiation.
Answer:
Non-repudiation: prevention against violation agreement after the deal.

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 4.
List the different types of security technologies in E-Commerce
Answer:

  • Encryption technology
  • Authentication technology
  • Authentication protocols

Question 5.
Write about digital signature.
Answer:

  1. A digital signature is a mechanism that is used to verify that a particular digital document, message, or transaction is authentic.
  2. Digital signatures are used to verify the trustworthiness of the data being sent.

Part III

Explain In Brief Answer

Question 1.
Write a note on certification authorities (CA)
Answer:

  • Digital certificates are issued by recognized Certification Authorities (CA).
  • When someone requests a digital certificate, the authority verifies the identity of the requester, and if the requester fulfills all requirements, the authority issues it.

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 2.
List some E-Commerce Security Threats?
Answer:

  • Information leakage
  • Tampering
  • Payment frauds
  • Malicious code threats
  • Distributed Denial of Service (DDoS) Attacks
  • Cyber Squatting
  • Typopiracy

Question 3.
Differentiate asymmetric and symmetric algorithms.
Answer:
Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems 1

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 4.
Write a note on PGP.
Answer:
Pretty Good Privacy (PGP): Phil Zimmermann developed PGP in 1991. It is a decentralized encryption program that provides cryptographic privacy and authentication for data communication. PGP encryption uses a serial combination of hashing, data compression, symmetric-key cryptography, and asymmetric-key cryptography and works on the concept of “web of trust”.

Question 5.
Explain 3D secure payment protocols
Answer:

  • “3-D Secure is a secure payment protocol on the Internet.
  • It was developed by Visa to increase the level of transaction security, and it has been adopted by MasterCard.
  • It gives a better authentication of the holder of the payment card, during purchases made on websites.
  • The basic concept of this (XML-based) protocol is to link the financial authorization process with an online authentication system.

This authentication model comprises 3 domains (hence the name 3D) which are:

  1. The Acquirer Domain
  2. The Issuer Domain
  3. The interoperability’ Domain

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Part IV

Explain In Detail

Question 1.
Write about dimensions of E-Commerce Security.
Answer:
The following are some of the security elements involved in E-Commerce:

  1. Authenticity: conforming genuineness of data shared.
  2. Availability: prevention against data delay or removal.
  3. Completeness: unification of all business information.
  4. Confidentiality: protecting data against unauthorized disclosure.
  5. Effectiveness: effective handling of hardware, software and data.
  6. Integrity: prevention of the data being unaltered or modified.
  7. Non-repudiation: prevention against violation agreement after the deal.
  8. Privacy: prevention of customers’ personal data being used by others.
  9. Reliability: providing a reliable identification of the individuals or businesses.
  10. Review ability: capability of monitoring activities to audit and track the operations.

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 2.
Explain encryption technology.
Answer:

  • Encryption technology is an effective information security protection.
  • It is defined as converting a Plaintext into meaningless Ciphertext using an encryption algorithm thus ensuring the confidentiality of the data.
  • The encryption or decryption process uses a key to encrypt or decrypt the data.

Types:
At present, two encryption technologies are widely used. They are:

  • Symmetric key encryption system
  • Asymmetric key encryption system.

Symmetric key encryption – Data Encryption Standard (DES):

  • It is a Symmetric-key data encryption method.
  • It is the typical block algorithm that takes a string of bits of clear text (plaintext) with a fixed length into another encrypted text of the same length.
  • It also uses a key to customize the transformation, so that, in theory, the algorithm can only be deciphered by people who know the exact key that has been used for encryption.
  • The DES key is apparently 64 bits, but in fact, the algorithm uses only 56. The other eight bits are only used to verify the parity and then it is discarded.
  • The key length increased by multiple uses of the DES, described as Triple-DES, also known as TDES, 3DES or DESede,

Asymmetric or Public key encryption

  • It is also called as RSA (Rivest-Shamir-Adleman) algorithm.
  • It uses public-key authentication and digital signatures.
  • Each user generates their own key pair, which consists of a private key and a public key.
  • A public-key encryption method is a method for converting a plaintext with a public key into a ciphertext from which the plaintext can be retrieved with a private key.

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 3.
Differentiate digital signatures and digital certificates.
Answer:

Symmetric Key Encryption

Symmetric Key Encryption

A digital signature is a mechanism that is used to verify that a particular digital document, message, or transaction is authentic. A digital certificate is a computer file which officially ap­proves the relation between the holder of the certificate and a particular public key.
Digital signatures are used to verify the trustworthiness of the data being sent Digital certificates are used to verify the trustworthiness of the sender
A digital signature is to ensure that data remains secure from the point it was issued and it was not modified by a third party. A digital certificate binds a digital signature to an entity
It provides authentication, non-repudiation, and in­tegrity It provides authentication and security
A digital signature is created using a Digital Signa­ture Standard (DSS). I use an SHA-1 or sha-2 algo­rithm for encrypting and decrypting the message. A digital certificate works on principles of public-key cry- pyrography standards (PKCS). It creates a certificate in the X.509 or PGP format.
The document is encrypted at the sending end and decrypted at the receiving end using asymmetric keys. A digital certificate consists of the certificate’s owner name and public key, expiration date, a certificate Authority’s name, a Certificate Authority’s digital signature

Question 4.
Define Secure Electronic Transaction (SET) and its features.
Answer:
There are two kinds of security authentication protocols widely used in E-Commerce, namely Secure Electronic Transaction (SET) and Secure Sockets Layer (SSL).

Secure Electronic Transaction:
Secure Electronic Transaction (SET) is a security protocol for electronic payments with credit cards, in particular via the Internet. SET was developed in 1996 by VISA and MasterCard, with the participation of GTE, IBM, Microsoft, and Netscape.

The implementation of SET is based on the use of digital signatures and the encryption of transmitted data with asymmetric and symmetric encryption algorithms. SET also use dual signatures to ensure privacy.

The SET purchase involves three major participants: the customer, the seller, and the payment gateway. Here the customer shares the order information with the seller but not with the payment gateway. Also, the customer shares the payment information only with the payment gateway but not with the seller.

So, with the SET, the credit card number may not be known to the seller and will not be stored in the seller’s files also could not be recovered by a hacker. The SET protocol guarantees the security of online shopping using credit cards on the open network. It has the advantages of ensuring the integrity of transaction data and the non-repudiation of transactions. Therefore, it has become the internationally recognized standard for credit card online transactions.

SET system incorporates the following key features:

  • Using public-key encryption and private key encryption ensure data confidentiality.
  • Use information digest technology to ensure the integrity of information.
  • Dual signature technology to ensure the identity of both parties in the transaction.

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 5.
Briefly explain SSL.
Answer:

  • The most common Cryptographic protocol is Secure Sockets Layers (SSL).
  • SSL is a hybrid encryption protocol for securing transactions over the Internet.
  • The SSL standard was developed by Netscape in collaboration with MasterCard, Bank of America, MCI, and Silicon Graphics.
  • It is based on a public key cryptography process to ensure the security of data transmission over the internet.

Principle:

  • To establish a secure communication channel (encrypted) between a client and a server after an authentication step.
  • To ensure the security of data, located between the application layer and the transport layer in TCP.

Example:

  • A user using an internet browser to connect to an SSL secured E-Commerce site will send encrypted data without any more necessary manipulations.

Advantages:

  • Today, all browsers ¡n the market support SSL.
  • The secure communications are proceeded, through this protocol.
  • SSL works completely hidden for the user, who does not have to intervene in the protocol.
  • The URL starts with https:// instead of http:// where the “s” obviously means secured. It is also preceded by a green padlock.

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

12th Computer Applications Guide E-Commerce Security Systems Additional Important Questions and Answers

Part A

Choose The Correct Answers:

Question 1.
A digital certificate is also known as ………………
a) Public key certificate
b) Asymmetric Key
c) Symmetric Key
d) All of the above
Answer:
a) Public key certificate

Question 2.
…………… is a process of taking down an E-Commerce site by sending continuous
overwhelming request to its server.
a) RSA
b) DES
c) DDoS
d) CA
Answer:
c) DDoS

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 3.
The stealing of online documents is called …………………….
(a) phishing
(b) virus
(c) Frauds
(d) information leakage
Answer:
(d) information leakage

Question 4.
Typopiracy is a variant of ………….
a) Payment Frauds
b) Tampering
c) Cybersquatting
d) All of the above
Answer:
c) Cybersquatting

Question 5.
How many types of payment frauds are there?
(a) 2
(b) 3
(c) 4
(d) 5
Answer:
(b) 3

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Abbreviations:

  1. DDoS Distributed Denial of Service
  2. DES Data Encryption Standard
  3. RSA Rivest-Shamir-Adleman
  4. CA Certification Authorities
  5. PGP Pretty Good Privacy
  6. PKI Public Key Infrastructure
  7. SET Secure Electronic Transaction
  8. SSL Secure Sockets Layers
  9. TLS Transport Layer Security
  10. MD Message Digest
  11. PIN Personal Identification Number
  12. OTP One Time Password
  13. FIPS Federal Information Processing Standard
  14. PKCS Public-key cryptography standards

Assertion And Reason

Question 1.
Assertion (A); A digital signature is a mechanism that is used to verify that a particular digital document, message, or transaction is authentic.
Reason (R); A digital certificate is a computer file which officially approves the relation between the holder of the certificate and a particular public key.
a) Both (A) and (R) are correct and (R) is the correct explanation of (A)
b) Both (A) and (R) are correct, but (R) is not the correct explanation of (A)
c) (A) is true and (R) is false
d) (A) is false and (R) is true
Answer:
b) Both (A) and (R) are correct, but (R) is not the correct explanation of (A)

Question 2.
Assertion (A): Digital signatures are used to verify the trustworthiness of the data being sent.
Reason (R): A digital signature is a mechanism that is used to verify that a particular digital document, message, or transaction is authentic.
a) Both (A) and (R) are correct and (R) is the correct explanation of (A)
b) Both (A) and (R) are correct, but (R) is not the correct explanation of (A)
c) (A) is true and (R) is false
d) (A) is false and (R) is true
Answer:
a) Both (A) and (R) are correct and (R) is the correct explanation of (A)

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 3.
Assertion (A): A digital certificate is created using a Digital Signature Standard (DSS). It uses an SHA-1 or SHA-2 algorithm for encrypting and decrypting the message.
Reason (R); A digital certificate consists of the certificate’s owner name and public key, expiration date, a Certificate Authority’s name a Certificate Authority’s digital signature.
a) Both (A) and (R) are correct and (R) is the correct explanation of (A)
b) Both (A) and (R) are correct, but (R) is not the correct explanation of (A)
c) (A) is true and (R) is false
d) (A) is false and (R) is true
Answer:
d) (A) is false and (R) is true

Question 4.
Assertion (A); At present, there are two kinds of security authentication protocols widely used in E-Commerce.
Reason (R): SET is a Cryptographic protocol.
a) Both (A) and (R) are correct and (R) is the correct explanation of (A)
b) Both (A) and (R) are correct, but (R) is not the correct explanation of (A)
c) (A) is true and (R) is false
d) (A) is false and (R) is true
Answer:
c) (A) is true and (R) is false

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 5.
Assertion (A)s URL starts with https://instead of http:// where the “s” obviously means secured.
Reason (R): SSL works completely hidden for the user, who does not have to intervene in the protocol.
a) Both (A) and (R) are correct and (R) is the correct explanation of (A)
b) Both (A) and (R) are correct, but (R) is not the correct explanation of (A)
c) (A) is true and (R) is false
d) (A) is false and (R) is true
Answer:
b) Both (A) and (R) are correct, but (R) is not the correct explanation of (A)

Very Short Answers

Question 1.
What is DES?
Answer:
The Data Encryption Standard (DES) is a Symmetric-key data encryption method.

Question 2.
When was DES introduced?
Answer:
It was introduced in America in the year 1976

Question 3.
Who introduced DES?
Answer:
It was introduced by Federal Information Processing Standard (FIPS).

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 4
Who developed PGP? When?
Answer:
Pretty Good Privacy (PGP): Phil Zimmermann developed PGP in 1991.

Question 5.
What is the use of digital certificates?
Answer:
Digital certificates are used to verify the Trust j worthiness of the sender.

Question 6.
What is the use of digital signatures?
Answer:
Digital signatures are used to verify the trustworthiness of the data being sent

Question 7.
Who developed 3D-Secure?
Answer:
3D-Secure was developed by Visa

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 8.
What is 3D-Secure?
Answer:
3-D Secure is a secure payment protocol on the Internet.

Question 9.
What is the purpose of 3D-Secure?
Answer:
To increase the level of transaction security,

Question 10.
What is the basic concept of 3D-Secure?
Answer:
To link the financial authorization process with an online authentication system.

Question 11.
What is SET?
Answer:
Secure Electronic Transaction (SET) is a security protocol for electronic payments

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 12.
What is SSL?
Answer:
The most common Cryptographic protocol is Secure Sockets Layers (SSL).

Question 13.
What is the purpose of SSL?
Answer:
To ensure the security of data transmission over the internet.

Question 14.
What are Brute-force attacks?
Answer:
It is the simplest attack method for breaking any encryption.

Question 15.
Who developed SSL?
Answer:
The SSL standard was developed by Netscape

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 16.
What is a repository?
Answer:
The certificate authority maintains a database of public keys called a repository

Question 17.
How TLS and SSL differ?
Answer:
TLS differs from SSL in the generation of symmetric keys.

Question 18.
How many domains are in the authentication model?
Answer:
There are 3 domains in the authentications model

Question 19.
When SSL renamed as TLS?
Answer:
Secure Sockets Layers (SSL) was renamed as Transport Layer Security (TLS) in 2001.

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 20.
What is the principle of SSL?
Answer:
To establish a secure communication channel between a client and a server

Question 21.
What is public key infrastructure?
Answer:
Digital signatures use a standard, worldwide accepted format, called Public Key Infrastructure (PKI).

Question 22.
What is the purpose of PKI?
Answer:
To provide the highest levels of security and universal acceptance.

Question 23.
What is the role of security certification in authentication technology?
Answer:
To ensure Authentication, Integrity, and Non-repudiation.

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 24.
Who are the participants involve in inset purchase?
Answer:

  • The customer
  • The seller
  • The payment gateway.

Question 25.
What is another name of Asymmetric encryption?
Answer:
RSA (Rivest-Shamir-Adleman) algorithm.

Important Years To Remember:

1976 DES was introduced in America
1991 Phil Zimmermann developed PGP
1996 SET was developed by VISA and MasterCard

Find The Odd One On The Following

1. a) Authenticity
b) Availability
c) Completeness
d) Audacity
Answer:
d) Audacity

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

2. a) Confidentiality
b) Effectiveness
c) Tampering
d) Reliability
Answer:
c) Tampering

3. a) Cyber Squatting
b) Integrity
c) Non-repudiation
d) Privacy
Answer:
a) Cyber Squatting

4. a) Information leakage
b) Confidentiality
c) Payment frauds
d) Tampering
Answer:
b) Confidentiality

5. a) Malicious code threats
b) DDoS
c) Cyber Squatting
d) Confidentiality
Answer:
d) Confidentiality

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

6. a) DES
b) AES
c) ECC
d) RC4
Answer:
c) ECC

7. a) DES
b) ECC
c) DSA
d) RSA
Answer:
a) DES

8. a) TDES
b) AES
c) 3 DES
d) DESede
Answer:
b) AES

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

9. a) Authentication
b) Integrity
c) Non-repudiation
d) Plain Text
Answer:
d) Plain Text

10. a) Asymmetric encryption
b) Symmetric key encryption
c) Data Encryption Standard
d) Federal Information Processing Standard
Answer:
a) Asymmetric encryption

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Part B

Short Answer Questions

Question 1.
What is E-commerce Security?
Answer:
E-Commerce security is a set of protocols that safely guide E-Commerce transactions through the Internet.

Question 2.
What is Cyber Squatting?
Answer:
It is s the illegal practice of registering an Internet domain name that might be wanted by another person in an intention to sell it later for a profit

Question 3.
What is meant by cybersquatting?
Answer:
Cyber Squatting: Cybersquatting is the illegal practice of registering an Internet domain name that might be wanted by another person with an intention to sell it later for a profit.

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Part c

Explain In Brief Answer

Question 1.
Define Phishing?
Answer:
Phishing is also an E-Commerce threat in which a target is contacted by e-mail, telephone, or text message by someone who pretends himself as a genuine authority. They try to trap individuals to provide sensitive data such as banking and credit card details, OTP, PIN, or passwords. Once they succeed, the results would lead to devastating acts such as identity theft and financial loss.

Question 2.
What are the subsets of Payment frauds?
Answer:

  • Friendly fraud (when customer demands false reclaim or refund
  • Clean fraud (when a stolen credit card is used to make a purchase)
  • Triangulation fraud (fake online shops offering cheapest price and collect credit card data) etc.

Samacheer Kalvi 12th Computer Applications Guide Chapter 17 E-Commerce Security Systems

Question 3.
Explain various types of payment frauds?
Answer:
Payment frauds: Payment frauds have subsets like Friendly fraud (when customer demands- false reclaim or refund), Clean fraud (when a stolen credit card is used to make a purchase) Triangulation fraud (fake online shops offering the cheapest price and collect credit card data), etc.

Question 4.
What is Distributed Denial of Service (DDoS) Attacks? Or What is network flooding?
Answer:

  • It is a process of taking down an E-Commerce site by sending a continuous overwhelming request to its server.
  • This attack will be conducted from numerous unidentified computers using a botnet. This attack will slow down and make the server inoperative.
  • DDoS attacks are also called network flooding.

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Tamilnadu State Board New Syllabus Samacheer Kalvi 12th Computer Applications Guide Pdf Chapter 18 Electronic Data Interchange – EDI Text Book Back Questions and Answers, Notes.

Tamilnadu Samacheer Kalvi 12th Computer Applications Solutions Chapter 18 Electronic Data Interchange – EDI

12th Computer Applications Guide Electronic Data Interchange – EDI Text Book Questions and Answers

Part I

Choose The Correct Answers

Question 1.
EDI stands for
a) Electronic Details Information
b) Electronic Data Information
c) Electronic Data Interchange
d) Electronic Details Interchange
Answer:
a) Electronic Details Information

Question 2.
Which of the following is an internationally recognized standard format for trade, transportation, insurance, banking and customs?
a) TSLFACT
b) SETFACT
c) FTPFACT
d) EDIFACT
Answer:
d) EDIFACT

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 3.
Which is the first industry-specific EDI standard?
a) TDCC
b) VISA
c) Master
d) ANSI
Answer:
a) TDCC

Question 4.
UNSM stands for
a) Universal Natural Standard Message
b) Universal Notations for Simple Message
c) United Nations Standard Message
d) United Nations Service Message
Answer:
c) United Nations Standard Message

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 5.
Which of the following is a type of EDI?
a) Direct EDI
b) Indirect EDI
c) Collective EDI
d) Unique EDI
Answer:
a) Direct EDI

Question 6.
Who is called the father of EDI?
a) Charles Babbage
b) Ed Guilbert
c) Pascal
d) None of the above
Answer:
b) Ed Guilbert

Question 7.
EDI interchanges start with ……………. and end with ……………
a) UNA, UNZ
b) UNB, UNZ
c) UNA, UNT
d) UNB, UNT
Answer:
b) UNB, UNZ

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 8.
EDIFACT stands for
a) EDI for Admissible Commercial Transport
b) EDI for Advisory Committee and transport
c) EDI for Administration, Commerce, and Transport
d) EDI for Admissible Commerce and Trade
Answer:
c) EDI for Administration, Commerce, and Transport

Question 9.
The versions of EDIFACT are also called as
a) Message types
b) Subsets
c) Directories
d) Folders
Answer:
c) Directories

Question 10.
Number of characters in a single EDIFACT messages
a) 5
b) 6
c) 4
d) 3
Answer:
b) 6

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Part II

Short Answers

Question 1.
Define EDI.
Answer:
The Electronic Data Interchange (EDI) is the exchange of business documents between one trade partner and another electronically. It is transferred through a dedicated channel or – through the Internet in a predefined format without much human intervention.

Question 2.
List few types of business documents that are transmitted through EDI.
Answer:

  1. Delivery notes
  2. Invoices
  3. Purchase orders
  4. Advance ship notice
  5. Functional acknowledgments etc.

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 3.
What are the 4 major components of EDI?
Answer:
There are four major components of EDI. They are:

  1. Standard document format
  2. Translator and Mapper
  3. Communication software
  4. Communication network

Question 4.
What is meant by directories inEDIFACT?
Answer:

  • The versions of EDIFACT are also called as directories.
  • These EDIFACT directories will he revised twice a year.

Question 5.
Write a note on EDIFACT subsets.
Answer:
Due to the complexity, branch-specific subsets of EDIFACT have developed. These subsets of EDIFACT include only the functions relevant to specific user groups.
Example:

  • CEFIC – Chemical industry
  • EDIFURN – furniture industry
  • EDIGAS – gas business

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Part III

Explain In Brief Answer

Question 1.
Write a short note on EDI.

  • The Electronic Data Interchange (EDI)is the exchange of business documents between one trade partner and another electronically,
  • It is transferred through a dedicated channel or through the Internet in a predefined format without much human intervention,
  • It is used to transfer documents such as delivery notes, invoices, purchase orders, advance ship notices, functional acknowledgments, etc.

Question 2.
List the various layers of EDI.
Answer:
Electronic data interchange architecture specifies four different layers namely

  1. Semantic layer
  2. Standa, us translation layer
  3. Transport layer
  4. Physical layer

These EDI layers describe how data flows from one computer to another.

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 3.
Write a note on UN/EDIFACT.
Answer:

  • United Nations / Electronic Data Interchange for Administration, Commerce, and Transport
  • (UN / EDIFACT) is an international EDI – a standard developed under the supervision of the United Nations.
  • In 1987, the UN / EDIFACT syntax rules were approved as ISO: IS09735 standard by the International Organization for Standardization.
  • EDIFACT includes a set of internationally agreed standards, catalogs, and guidelines for the electronic exchange of structured data between independent computer systems.

Question 4.
Write a note on the EDIFACT message.
Answer:

  • The basic standardization concept of EDIFACT is that there are uniform message types called United Nations Standard Message (UNSM).
  • In so-called subsets, the message types can be specified deeper in their characteristics depending on the sector.
  • The message types, all of which always have exactly one nickname consisting of six uppercase English alphabets.
  • The message begins with UNH and ends with UNT.

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 5.
Write about EDIFACT separators
Answer:
EDIFACT has the following punctuation marks that are used as standard separators.
Character Uses

Character

Uses

Apostrophe (‘) segment terminator
Plus sign (+) segment tag and data element separator
Colon (;) component data element separator
Question mark (?) Release character
Period (.) decimal point

Part IV

Explain In Detail

Question 1.
Briefly explain various types of EDI.
Answer:
The types of EDI were constructed based on how EDI communication connections and the conversion were organized. Thus based on the medium used for transmitting EDI documents the following are the major EDI types.

  1. Direct EDI
  2. EDI via VAN
  3. EDI via-FTP/VPN, SFTP, FTPS
  4. Web EDI
  5. Mobile EDI
  6. Direct EDI/Point-to-Point

It is also called as Point-to-Point EDI. It establishes a direct connection between various business stakeholders and partners individually. This type of EDI suits to larger businesses with a lot of day to day business transactions.

EDI via VAN:
EDI via VAN (Value Added Network) is where EDI documents are transferred with the support of third-party network service providers. Many businesses prefer this network model to protect them from the updating ongoing complexities of network technologies.

EDI via FTP/VPN, SFTP, FTPS:
When protocols like FTP/VPN, SFTP, and FTPS are used for the exchange of EDI-based documents through the Internet or Intranet it is called EDI via FTP/VPN, SFTP, FTPS.

Web EDI:
Web-based EDI conducts EDI using a web browser via the Internet. Here the businesses are allowed to use any browser to transfer data to their business partners. Web-based EDI is easy and convenient for small and medium organizations.

Mobile EDI:
When smartphones or other such handheld devices are used to transfer EDI documents it is called mobile EDI. Mobile EDI applications considerably increase the speed of EDI transactions.

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 2.
What are the advantages of EDI?
Answer:

  • EDI was developed to solve the problems inherent in paper-based transaction processing and in other forms of electronic communication.
  • Implementing an EDI system offers a company greater control over its supply chain and allow it to trade more effectively. It also increases productivity and promotes operational efficiency.

The following are the other advantages of EDI.

  • Improving service to end-users
  • Increasing productivity
  • Minimizing errors
  • Slashing response times
  • Automation of operations
  • Cutting costs
  • Integrating all business and trading partners

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 3.
Write about the structure of EDIFACT.
Answer:

  • EDIFACT is a hierarchical structure where the top level is referred to as an interchange, and lower levels contain multiple messages.
  • The messages consist of segments, which in turn consist of composites.
  • The final iteration is a data element.

Segment Tables

  • The segment table lists the message tags.
  • It contains the tags, tag names, requirements designator, and repetition field.
  • The requirement designator may be mandatory (M) or conditional (C).
  • The (M) denotes that the segment must appear at least once. The (C) denotes that the segment may be used if needed.
  • Example: CIO indicates repetitions of a segment or group between 0 and 10.

EDI Interchange

  • Interchange is also called an envelope.
  • The top-level of the EDIFACT structure is Interchange.
  • An interchange may contain multiple messages. It starts with UNB and ends with UNZ

EDIFACT message

  • The basic standardization concept of EDIFACT is that there are uniform message types called United Nations Standard Message (UNSM).
  • In so-called subsets, the message types can be specified deeper in their characteristics depending on the sector.
  • The message types, all of which always have exactly one nickname consisting of six uppercase English alphabets.
  • The message begins with UNH and ends with UNT

Service messages

  • To confirm/reject a message, CONTRL and APERAK messages are sent.
  • CONTRL- Syntax Check and Confirmation of Arrival of Message
  • APERAK – Technical error messages and acknowledgment

Data exchange

  • CREMUL – multiple credit advice
  • DELFOR- Delivery forecast
  • IFTMBC – Booking confirmation

EDIFACT Segment

  • It is the subset of messages.
  • A segment is a three-character alphanumeric code.
  • These segments are listed in segment tables.
  • Segments may contain one, or several related user data elements.

EDIFACT Elements

  • The elements are the piece of actual data.
  • These data elements may be either simple or composite.

EDI Separators
EDIFACT has the following punctuation marks that are used as standard separators.

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

12th Computer Applications Guide Electronic Data Interchange – EDI Additional Important Questions and Answers

Part A

Choose The Correct Answers

Question 1.
……………………. is the exchange of business documents between one trade partner and another electronically.
(a) EDI
(b) UDI
(c) FDI
(d) DDI
Answer:
(a) EDI

Question 2.
First EDI standards were released by ………..
a) EDI
b) EFT
c) EDIA
d) TDCC
Answer:
d) TDCC

Question 3.
……………………. is a paperless trade.
(a) EDI
(b) XML
(c) EDIF
(d) EFT
Answer:
(a) EDI

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 4.
………… establishes a direct connection between various business stakeholders
and partners individually.
a) Direct EDI
b) EDI via VAN
c) Web EDI
d) Mobile EDI
Answer:
a) Direct EDI

Question 5.
Electronic data interchange architecture specifies ……………. different layers.
a) two
b) three
c) four
d) five
Answer:
c) four

Question 6.
TDCC was formed in the year …………………….
(a) 1964
(b) 1966
(c) 1968
(d) 1970
Answer:
(c) 1968

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 7.
In ……………… UN created the EDIFACT to assist with the global reach of technology in E-Commerce.
a)1985
b)1978
c)1974
d)1975
Answer:
a)1985

Question 8.
Expand EDIA
(a) Electronic Data Interchange Authority
(b) Electronic Data Information Association
(c) Electronic Data Interchange Association
(d) Electronic Device Interface Amplifier
Answer:
(c) Electronic Data Interchange Association

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 9.
Which of the following is for the exchange of EDI-based documents through the Internet?
a) FTP/VPN
b) SFTP
c) FTPS
d) All of the above
Answer:
d) All of the above

Question 10.
EDIA has become …………………….. committee.
(a) ANSIXI2
(b) ANSIXI3
(c) ANSIXI4
(d) ANSIX15
Answer:
(a) ANSIXI2

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Fill In The Blanks:

1. ……….. was developed to solve the problems inherent in paper-based transaction processing.
Answer:
EDT

2. ………….. is also called as Point-to-Point EDI.
Answer:
Direct EDT

3. Interchange is also called…………..
Answer:
Envelope

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

4. EDT is ……………… Trade.
Answer:
Paperless

5. EFT is …………….. Payment
Answer:
Paperless

6. ………… is “the computer-to-computer interchange of strictly formatted messages.
Answer:
EDI

7. …………….. EDI is easy and convenient for small and medium organizations.
Answer:
Web-based

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

8. The …………. is the most critical part of the entire EDI.
Answer:
standard

Abbreviations

  1. EDI – Electronic Data Interchange
  2. EFT – Electronic Transfer
  3. TDCC – Transportation Data Coordinating Committee
  4. EDIA – Electronic Data Interchange Association
  5. ANSI – American National Standards Institute
  6. VAN – Value Added Network
  7. ANSI ASC – American National Standards Institute Accredited Standard Committee
  8. GTDI – Guideline for Trade Data Interchange
  9. UN/ECE/ – United -Nations Economic Commission for Europe
  10. UN/EDIFACT -United Nations / Electronic Data Interchange for Administration, Commerce, and Transport
  11. UNSM -United Nations Standard Message

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Assertion And Reason
Question 1.
Assertion (A): According to the National Institute of Standards and Technology, EDI is the computer-to-computer interchange of strictly formatted messages that represent documents other than monetary instruments.
Reason(R): The Electronic Data Interchange (EDI) is the exchange of business documents between one trade partner and another electronically.
a) Both (A) and (R) are correct and (R) ¡s the correct explanation of (A)
b) Both (A) and (R) are correct, but (R) is not the correct explanation of (A)
c) (A) is true and (R) is false
d) (A) is false and (R) is true
Answer:
b) Both (A) and (R) are correct, but (R) is not the correct explanation of (A)

Question 2.
Assertion(A): EFT is “Paperless Trade”
Reason(R): The Electronic Data Interchange (EDI) is the exchange of business documents between one trade partner and another electronically.
a) Both (A) and (R) are correct and (R) is the correct explanation of (A)
b) Both (A) and (R) are correct, but (R) is not the correct explanation of (A)
c) (A) is true and (R) is false
d) (A) is false and (R) is true
Answer:
d) (A) is false and (R) is true

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 3,
Assertion (A): United Nations / Electronic Data Interchange for Administration, Commerce, and Transport (UN / EDIFACT) is an international EDI – a standard developed under the supervision of the United Nations.
Reason(R): In 1985, the UN / EDIFACT syntax rules were approved as ISO: IS09735 standard by the International Organization for Standardization.
a) Both (A) and (R) are correct and (R) is the correct explanation of (A)
b) Both (A) and (R) are correct, but (R) is not the correct explanation of (A)
c) (A) is true and (R) is false
d) (A) is false and (R) is true
Answer:
c) (A) is true and (R) is false

Question 4.
Assertion (A): The segment table lists the message tags.
Reason(R): It contains the tags, tag names, requirements designator, and repatriation field.
a) Both (A) and (R) are correct and (R) is the correct explanation of (A)
b) Both (A) and (R) are correct, but (R) is not the correct explanation of (A)
c) (A) is true and (R) is false
d) (A) is false and (R) is true
Answer:
a) Both (A) and (R) are correct and (R) is the correct explanation of (A)

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 5.
Assertion (A): The top level of EDIFACT structure is Interchange.
Reason(R): Interchange is also called an envelope. An interchange may contain multiple messages. It starts with UNB and ends with UNZ
a) Both (A) and (R) are correct and (R) is the correct explanation of (A)
b) Both (A) and (R) are correct, but (R) is not the correct explanation of (A)
c) (A) is true and (R) is false
d) (A) is false and (R) is true
Answer:
a) Both (A) and (R) are correct and (R) is the correct explanation of (A)

Short Answer Questions

Question 1.
Who is the father of EDI?
Answer:
Ed Guilbert is called the father of EDI

Question 2.
What is Paperless trade?
Answer:
The exchange of business documents between one trade partner and another electronically is called Paperless trade.

Question 3.
What is Paperless Payment?
Answer:
Transfer of money from one bank account to another, via computer-based systems, is known as Paperless payment

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 4.
What is another name of Direct EDI?
Answer:
Another name of Direct EDI is Point-to-Point EDI.

Question 5.
How many alphabets require for EDI messages?
Answer:
Every EDI message requires six uppercase English Alphabets

Match The Following:

1. EDI – Booking confirmation
2. EFT – Paperless Trade
3. EDIFACT – Envelope
4. Interchange – Delivery forecast
5. CEFIC – Directories
6. EDIFURN – Chemical industry
7. EDIGAS – Technical error
8. CONTRL – Multiple credit advice
9. APERAK – Furniture industry
10. CREMUL – Arrival of Message
11. DELFOR – Gas business
12. IFTMBC – Paperless Payment

Answers
1. Paperless Trade
2. Paperless Payment
3. Directories
4. Envelope
5. Chemical industry
6. Furniture industry
7. Gas business
8. Arrival of Message
9. Technical error
10. Multiple credit advice
11. Delivery forecast
12. Booking confirmation

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Find The Odd One On The Following

1. (a) Deliver/ Notes
(b) Invoices
(c) Advance Ship Notice
(d) EDIFACT
Answer:
(d) EDIFACT

2. (a) EDIFACT
(b) XML
(c) CDMA
(d) ANSI ASCX12
Answer:
(c) CDMA

3. (a) Direct EDI
(b) InDirectEDI
(c) Web EDI
(d) Mobile EDI
Answer:
(b) InDirectEDI

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

4. (a) FTP/VPN
(b) HTTP
(c) SFTPP
(d) FTPS
Answer:
(b) HTTP

5. (a) Dial-Up Line
(b) I way
(c) point to point
(d) Internet
Answer:
(c) point to point

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

6. (a) Email
(b) MIME
(c) HTTP
(d) ANSI X12
Answer:
(d) ANSI X12

7. (a) Transport Layer
(b) Semantic Layer
(c) Application Layer
(d) physical Layer
Answer:
(c) Application Layer

8. (a) Standards
(b) Catalogs
(c) TDCC
(d) guidelines
Answer:
(c) TDCC

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

9. (a) CREMUL
(b) DELFOR
(c) APERAK
(d) IFTMBC
Answer:
(c) APERAK

10. (a) Segment Terminator
(b) : – component data
(c) ? – data element separator
(d). – decimal point
Answer:
(c) ? – data element separator

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Important Years To Remember:

1975 First EDI standards were released by TDCC
1977 Drafting and using an EDI project begin
1978 TDCC is renamed as Electronic Data Interchange Association (EDIA)
1979 ANSI ASC developed ANSI X12
1985 UN created the EDIFACT
1986 UN/EDIFACT is officially proposed
1987 UN / EDIFACT syntax rules were approved

Part B

Short Answers

Question 1.
What is VAN?
Answer:
A value-added network is a company, that is based on its own network, offering EDI services to other businesses. A value-added network acts as an intermediary between trading partners. The principal operations of value-added networks are the allocation of access rights and providing high data security.

Question 2.
What are the types of EDI?
Answer:

  1. Direct EDI
  2. EDI via VAN
  3. EDI via FTP/VPN, SFTP, FTPS
  4. Web EDI
  5. Mobile EDI

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 3.
Write a short note on the Segment Table?
Answer:
Segment Tables:
The segment table lists the message tags. It contains the tags, tag names, requirements designator, and repetitation field. The requirement designator may be mandatory (M) or conditional (C). The (M) denotes that the segment must appear atleast once. The (C) denotes that the segment may be used if needed.

Question 4.
Mention some International accepted EDI Standards.
Answer:

  • EDIFACT
  • XML
  • ANSI
  • ASC XI2,

Part C

Brief Answers

Question 1.
Write a short note on EDIFACT Structure.
Answer:

  • EDIFACT is a hierarchical structure where the top level is referred to as an interchange, and lower levels contain multiple messages.
  • The messages consist of segments, which in turn consist of composites.
  • The final iteration is a data element.

Question 2.
What is EDI interchange?
Answer:

  • The top-level of the EDIFACT structure is Interchange.
  • An interchange may contain multiple messages.
  • It starts with UNB and ends with UNZ

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 3.
What is the EDI segment?
Answer:

  • A segment is a three-character alphanumeric code.
  • These segments are listed in segment tables.
  • Segments may contain one, or several related user data elements.

Question 4.
Write a note on EDI Interchange?
Answer:
EDI Interchange:
Interchange is also called an envelope. The top-level of the EDIFACT structure is Interchange. An interchange may contain multiple messages. It starts with UNB and ends with UNZ.

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Part D

Detailed Answers

Question 1.
Explain EDI standards?
Answer:
EDI Standards:

  • The standard is the most critical part of the entire EDI. Since EDI is the data transmission and information exchange in the form of an agreed message format, it is important to develop a unified EDI standard.
  • The EDI standard is mainly divided into the following aspects: basic standards, code-standards, message standards, document standards, management standards, application standards, communication standards, and security standards.
  • The first industry-specific EDI standard was the TDCC published by the Transportation Data Coordinating Committee in 1975.
  • Then other industries started developing unique standards based on their individual needs. E.g. WINS in the warehousing industry.
  • Since the application of EDI has become more mature, the target of trading operations is often not limited to a single industry.
  • In 1979, the American National Standards Institute Accredited Standard Committee (ANSI ASC) developed a wider range of EDI standards called ANSI XI2.
  • On the other hand, the European region has also developed an integrated EDI standard. Known as GTDI (Guideline for Trade Data Interchange).
  • ANSI X12 and GTDI have become the two regional EDI standards in North America and Europe respectively.
  • After the development of the two major regional EDI standards and a few years after the trial, the two standards began to integrate and conduct research and development of common EDI standards.
  • Subsequently, the United Nations Economic Commission for Europe (UN/ECE/WP.4) hosted the task of the development of international EDI standards. In 1986, UN/EDIFACT is officially proposed. The most widely used EDI message standards are the United Nations EDIFACT and the ANSI X12.

Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI

Question 2.
Draw the structure of the UN/EDIFACT message.
Samacheer Kalvi 12th Computer Applications Guide Chapter 18 Electronic Data Interchange – EDI 1

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Tamilnadu State Board New Syllabus Samacheer Kalvi 12th Computer Science Guide Pdf Chapter 7 Python Functions Text Book Back Questions and Answers, Notes.

Tamilnadu Samacheer Kalvi 12th Computer Science Solutions  Chapter 7 Python Functions

12th Computer Science Guide Python Functions Text Book Questions and Answers

I. Choose the best answer (I Marks)

Question 1.
A named blocks of code that are designed to do one specific job is called as
a) Loop
b) Branching
c) Function
d) Block
Answer:
c) Function

Question 2.
A Function which calls itself is called as
a) Built-in
b) Recursion
c) Lambda
d) return
Answer:
b) Recursion

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 3.
Which function is called anonymous un-named function PTA –
a) Lambda
b) Recursion
c) Function
d) define
Answer:
a) Lambda

Question 4.
Which of the following keyword is used to begin the function block?
a) define
b) for
c) finally
d) def
Answer:
d) def

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 5.
Which of the following keyword is used to exit a function block?
a) define
b) return
c) finally
d) def
Answer:
b) return

Question 6.
While defining a function which of the following symbol is used.
a) ; (semicolon)
b) . (dot)
c) : (colon)
d) $ (dollar)
Answer:
c): (colon)

Question 7.
In which arguments the correct positional order is passed to a function?
a) Required
b) Keyword
c) Default’
d) Variable-length
Answer:
a) Required

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 8.
Read the following statement and choose the correct statement(s).
I) In Python, you don’t have to mention the specific data types while defining function.
II) Python keywords can be used as function name.
a) I is correct and II is wrong
b) Both are correct
c) I is wrong and II is correct
d) Both are wrong
Answer:
a) I is correct and II is wrong

Question 9.
Pick the correct one to execute the given statement successfully, if ………… : print
(x, ” is a leap year”)
a) x%2=0
b) x%4==0
c) x/4=0
d) x%4=0
Answer:
b) x%4==0

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 10.
Which of the following keyword is used to define the function testpython(): ?
a) define
b) pass
c) def
d) while
Answer:
c) def

II. Answer the following questions (2 Marks)

Question 1.
What is a function?
Answer:
Functions are named blocks of code that are designed to do a specific job. If you need to perform that task multiple times throughout your program, you just call the function dedicated to handling that task.

Question 2.
Write the different types of functions.
Answer:

  1. User-defined functions
  2. Built-in functions
  3. Lambda functions
  4. Recursive functions

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 3.
What are the main advantages of function?
Answer:

  • It avoids repetition and makes high degree of code reusing.
  • It provides better modularity for your application.

Question 4.
What is meant by scope of variable? Mention its types.
Answer:

  • Scope of variable refers to the part of the program, where it is accessible, i.e., area where the variables can refer (use).
  • The scope holds the current set of variables and their values.
  • The two types of scopes are – local scope and global scope

Question 5.
Define global scope.
Answer:
A variable, with global scope can be used anywhere in the program. It can be created by defining a variable outside the scope of any function/block.

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 6.
What is the base condition in a recursive function
Answer:

  • A recursive function calls itself. Imagine a process would iterate indefinitely if not stopped by some condition. Such a process is known as infinite iteration.
  • The condition that is applied in any recursive function is known as a base condition.
  • A base condition is must in every recursive function otherwise it will continue to execute like an infinite loop.

Question 7.
How to set the limit for recursive function? Give an example.
Answer:
Python also allows you to change the limit using sys.setrecursionlimit (limit value).
Example:
import sys
sys.setrecursionlimit(3000)
def fact (n):
if n = = 0:
return 1
else:
return n * fact (n – 1)
print (fact (2000))

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

III. Answer the following questions (3 Marks)

Question 1.
Write the rules of the local variable.
Answer:

  • A variable with a local scope can be accessed only within the function or block that it is created in.
  • When a variable is created inside the function/block, the variable becomes local to it.
  • A local variable only exists while the function is executing.
  • The format arguments are also local to function.

Question 2.
Write the basic rules for a global keyword in python.
Answer:

  • When we define a variable outside a function, it’s global by default. We don’t have to use the global keyword.
  • We use a global keyword to read and write a global variable inside a function.
  • Use of global keyword outside a function has no effect.

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 3.
What happens when we modify the global variable inside the function?
Answer:
It will change the global variable value outside the function also.

Question 4.
Differentiate ceil() and floor() function?

Cell()

Floor ()

ceil () returns the smallest integer greater than or equal to the given value. floor() returns the largest integer less than or equal to the given value.

Question 5.
Write a Python code to check whether a given year is leap year or not
Answer:
n = int (input(“Enter any year”))
if (n % 4 = = 0):
print “Leap year”
else:
print “Not a Leap year”
Output:
Enter any year 2001
Not a Leap year

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 6.
What is a composition in functions?
Answer:

  • The value returned by a function may be used as an argument for another function in a nested manner is called composition.
  • For example, if we wish to take a numeric value or an expression as a input from the user, we take the input string from the user using the function input() and apply eval() function to evaluate its value

Question 7.
How recursive function works?
Answer:

  • Recursive function is called by some external code.
  • If the base condition is met then the program gives meaningful output and exits.
  • Otherwise, the function does some required processing and then calls itself to continue recursion.

Question 8.
What are the points to be noted while defining a function?
Answer:

  • Function blocks begin with the keyword “def”followed by function name and parenthesis() .
  • Any input parameters or arguments should be placed within these parentheses when you define a function.
  • The code block always comes after colon(;) and is indented.
  • The statement “return [expression]” exits a function, optionally passing back an expression to the caller.
  • A “return” with no arguments is the same as return None.

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

IV. Answer the following questions (5 Marks)

Question 1.
Explain the different types of function with an example.
Answer:

Functions

Description

User-defined functions Functions defined by the users themselves
Built-in functions Functions that are inbuilt within Python.
Lambda functions Functions that are anonymous un-named function.
Recursive functions Functions that call themselves is known as recursive.

1. User-defined function:
Functions defined by the users themselves are called User-defined functions.
Syntax:
def :
< Block of statement >
return < expression / None>
Example:
def welcome():
print(“Welcome to Python”)
return

2. Built-in functions:
Functions which are using Python libraries are called Built-in functions.
Example:
x=20
y=-23
print(‘First number = ” ,x)
print(‘Second number = ” ,y)
Output:
First number = 20
Second number = 23
3. Lambda function:

  • Lambda function is mostly used for creating small and one-time anonymous function.
  • Lambda functions are mainly used in combination with the functions like filter]), map]) and reduce]).
    Syntax of Lambda function (Anonymous Functions):
    lambda [argument(s)]: expression

Example:
sum = lambda arg1, arg2: arg1 + arg2
print (The Sum is :’, sum(30, 40)
print (The Sum is sum(-30, 40)

Output:
The Sum is: 70
The Sum is: 10

4. Recursive function:

  • A recursive function calls itself. Imagine a process would iterate indefinitely if not stopped by some condition! Such a process is known as infinite iteration.
  • The condition that is applied in any recursive function is known as a base condition.
  • A base condition is must in every recursive function otherwise it will continue to execute like an infinite loop.
  • Overview of how recursive function works:
  • Recursive function is called by some external code.
  • If the base condition is met then the. program gives meaningful output and exits.
  • Otherwise, function does some required processing and then calls itself to continue recursion.
    Here is an example of recursive function used to calculate factorial.

Example:
def fact(n):
if n==0:
return 1
else:
return n * fact (n-1)
print (fact (0))
print (fact (5))

Output:
1
120

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 2.
Explain the scope of variables with an example.
Answer:
Scope of Variables:
Scope of variable refers to the part of the program, where it is accessible, i.e., an area where you can refer (use) it. We can say that scope holds the current set of variables and their values.
The two types of scopes are local scope and global scope.

(I) Local scope:
A variable declared inside the function’s body or in the local scope is called a local variable.

Rules of local variable:

  1. A variable with local scope can be accessed only within the function/block that it is created in.
  2. When a variable is created inside the function/block; the variable becomes local to it.
  3. A local variable only exists while the function is executing.
  4. The formate arguments are also local to function.

Example: Create a Local Variable
def loc ( ):
y = 0 # local scope
print (y)
loc ( )
Output:
0
(II) Global Scope:
A variable, with global scope can be used anywhere in the program. It can be created by defining a variable outside the scope of any function/block.

Rules of global Keyword:
The basic rules for global keyword in Python are:

  1. When we define a variable outside a function, it’s global by default. You don’t have to useglobal keyword.
  2. We use global keyword to read and write a global variable inside a function.
  3. Use of global keyword outside a function has no effect

Example: Global variable and Local variable with same name
x = 5 def loc ( ):
x = 10
print (“local x:”, x)
loc ( )
print (“global x:”, x)
Output:
local x: 10
global x: 5
In the above code, we used same name ‘x’ for both global variable and local variable. We get a different result when we print same variable because the variable is declared in both scopes, i.e. the local scope inside the function loc() and global scope outside the function loc ( ).
The output:- local x: 10, is called local scope of variable.
The output: – global x: 5, is called global scope of variable.

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 3.
Explain the following built-in functions.
Answer:
a) id()
b) chr()
c) round ()
d) type()
e) pow()
Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions 1
Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions 2

Question 4.
Write a Python code to find the L.C.M. of two numbers.
Answer:
Program:
# Python Program to find the L.C.M. of two input number
defcompute_lcm(x, y):
# choose the greater number
if x > y:
greater = x
else:
greater = y
while (True):
if((greater % x == 0) and (greater % y == 0)):
1cm = greater
break
greater += 1
return 1cm
num1=int(input(//Enter first number=”))
num2=int(input(“Enter second number=”))
print
(“The L.C.M. is”, compute_lcm(num1, num2))
Output:
Enter first number=8
Enter second number=4
The L.C.M. is 8

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 5.
Explain the recursive function with an example.
Answer:
Python recursive functions
When a function calls itself is known as recursion. Recursion works like loop but sometimes it makes more sense to use recursion than loop. You can convert any loop to recursion.
A recursive function calls itself. Imagine a process would iterate indefinitely if not stopped by some condition! Such a process is known as infinite iteration. The condition that is applied in any recursive function is known as base condition. A base condition is must in every recursive function otherwise it will continue to execute like an infinite loop.

Working Principle:

  1. Recursive function is called by some external code.
  2. If the base condition is met then the program gives meaningful output and exits.
  3. Otherwise, function does some required processing and then calls itself to continue recursion. Here is an example of recursive function used to calculate factorial.

Example:
def fact (n):
if n = = 0:
return 1
else:
return n * fact (n – 1)
print (fact (0))
print (fact (5))
Output:
1
120

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

12th Computer Science Guide Python Functions Additional Questions and Answers

I. Choose the best answer

Question 1.
The name of the function is followed by ………………………….
(a) ( )
(b) [ ]
(c) <>
(d) { }
Answer:
(a) ( )

Question 2.
Which of the following provides better modularity for your python application
a) tuples
b) function
c) dictionaries
d) control structures
Answer:
b) function.

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 3.
How many types of functions are there in python?
a) 3
b) 2
c) 4
d) 5
Answer:
c) 4

Question 4.
Functions that call itself are known as
a) User-defined
b) Built-in
c) Recursive
d) Lambda
Answer:
c) Recursive

Question 5.
If the return has no argument, …………………………….. will be displayed as the last statement of the output.
(a) No
(b) None
(c) Nothing
(d) No value
Answer:
(b) None

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 6.
In which of the following the number of arguments in the function call should match exactly with the function definition?
a) Keyword arguments
b) Required arguments
c) Default arguments
d) Variable-length arguments
Answer:
b) Required arguments

Question 7.
Which of the following is used to define variable-length arguments?
a) $
b) *
c) #
d) //
Answer:
b) *

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 8.
What is the symbol used to denote variable-length arguments?
(a) +
(b) *
(c) &
(d) ++
Answer:
(b) *

Question 9.
Which function can take any number of arguments and must return one value in the form of an expression?
a) user-defined
b) recursive
c) default
d) lambda
Answer:
d) lambda

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 10.
How many return statement is executed at runtime?
a) 2
b) multiple
c) 3
d) 1
Answer:
d) 1

Question 11.
How many types of scopes in Python?
a) 3
b) 4
c) many
d) 2
Answer:
d) 2

Question 12.
Lambda functions cannot be used in combination with ………………………….
(a) Filter
(b) Map
(c) Print
(d) Reduce
Answer:
(c) Print

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 13.
Function blocks begin with the keyword …………………
a) Fun
b) Definition
c) Function
d) Def
Answer:
d) Def

Question 14.
………………. function can only access global variables.
a) user-defined
b) recursive
c) Lambda
d) return
Answer:
c) Lambda

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 15.
Find the correct one:
(a) Global keyword outside the function has no effect
(b) Global keyword outside the function has an effect
Answer:
(a) Global keyword outside the function has no effect

II. Answer the following questions (2 and 3 Marks)

Question 1.
Define nested blocks?
Answer:
Nested Block:
A block within a block is called a nested block. When the first block statement is indented by a single tab space, the second block of statement is indented by double tab spaces.

Question 2.
Differentiate parameters and arguments.
Answer:

Parameters

Arguments

Parameters are the variables used in the function definition. Arguments are the values we pass to the function parameters.

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 3.
Differentiate parameters and arguments?
Answer:
Parameters are the variables used in the function definition whereas arguments are the values we pass to the function parameters.

Question 4.
Write the syntax of variable-length arguments.
Answer:
def function_name(*args):
function_body
return_statement

Question 5.
What are the methods used to parse the arguments to the variable length arguments?
Answer:
In Variable Length arguments, we can parse the arguments using two methods.

  • Non-keyword variable arguments
  • Keyword variable arguments

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 6.
What is a local variable?
Answer:
A variable declared inside the function’s body or in the local scope is known as a local variable.

Question 7.
What are the two methods of passing arguments in variable-length arguments?
Answer:
In Variable Length arguments, we can pass the arguments using two methods.

  1. Non-keyword variable arguments
  2. Keyword variable arguments

Question 8.
Write a note on return statement?
Answer:
The return Statement

  1. The return statement causes your function to exit and returns a value to its caller. The point of functions in general is to take inputs and return something.
  2. The return statement is used when a function is ready to return a value to its caller. So, only one return statement is executed at run time even though the function contains multiple return statements.
  3. Any number of ‘return’ statements are allowed in a function definition but only one of them is executed at run time.

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 9.
Write a note on min (), max () and sum () with an example
Answer:
Function: min ()
Description: Returns the minimum value in a list.
Syntax: min (list)
Example:
My List = [21,76,98,23]
print (‘Minimum of My List:’,
min(My List))
Output:
Minimum of My List: 21
Function.: max ()
Description:
Returns the maximum value in a list.
Syntax : min (list)
Example:
My List = [21,76,98,23]
print (‘maximum of My List :‘, max
(my list)
Output:
Maximum of My List: 98
Function : sum ()
Description:
Returns the sum of values in a list.
Syntax :sum (list)
Example:
My List = [21,76,98,23]
print (Sum of My List :‘, sum(My List))
Output:
Sum of My List :218

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 10.
Write a note on the floor, cell () and sqrt () with an example
Answer:
Function: floor ()
Description: Returns the largest integer
less than or equal to x.
Syntax: math.floor (x)
Example:
x=26.7
y=-26.7
print (math.floor (x))
print (math.floor (y))
Output:
26
-27
Function: ceil ()
Description: Returns the smallest integer greater than or equal to x.
Syntax: math.ceil (x)
Example:
x=26.7
y=-26.7
print (math.ceil (x))
print (math.ceil (y))
Output:
27
-26 . ‘
Function : sqrt ()
Description: Returns the square root of x (Note: x must be greater than zero) Syntax: sqrt (x)
Example:
a=49
b= 25
print (math.sqrt (a))
print (math.sqrt (b))
Output:
7.0
5.0

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

Question 11.
Write a note on the format () with an example.
Answer:
Function: format ()
Description:
Returns the output based on the given format.

  • Binary format: Outputs the number in base 2.
  • Octal format: Outputs the number in base 8.
  • Fixed-point notation: Displays the number as a fixed-point number. The default precision is 6.

Syntax : format (value [‚format_spec])
Example:
x=14
y=25
print (‘x value in binary :’,format(x/b’))
print (‘y value in octal ^formatfy/o’))
print(‘y value in Fixed-point no ‘,format(y/f’))
Output:
x value in binary: 1110
y value in octal: 31
y value in Fixed-point no : 25.000000

Samacheer Kalvi 12th Computer Science Guide Chapter 7 Python Functions

III. Answer the following questions (5 Marks)

Question 1.
Explain different types of arguments used in python with an example.
Answer:

  • Arguments are used to call a function.
  • There are primarily four types of functions namely:
    1. Required arguments
    2. Keyword arguments,
    3. Default arguments
    4. Variable-length arguments.

Required Arguments:

  • “Required Arguments” are the arguments passed to a function in correct positional order.
  • The number of arguments in the function call should match exactly with the function definition.
  • Atleast one parameter to prevent syntax errors to get the required output.

Example:
defprintstring(str):
print (“Example – Required arguments”)
print (str)
return
# Now you can call printstring() function
printstring (“Welcome”)

Output:
Example – Required arguments Welcome
When the above code is executed, it
produces the following error.
Traceback (most recent call last):
File “Req-arg.py”, line 10, in < module >
printstring()
TypeError: printstring() missing 1
required positional argument: ‘str’
Instead of printstring() in the above code if we use printstring (“Welcome”) then the output is
Output:
Example – Required arguments Welcome

Keyword Arguments:

  • Keyword arguments will invoke the function after the parameters are recognized by their parameter names.
  • The value of the keyword argument is matched with the parameter name and so, one can also put arguments in improper order (not in order).

Example:
def printdata (name):
print (“Example-1 Keyword arguments”)
print (“Name : “:name)
return
# Now you can call printdatat() function
print data(name = “Gshan”) When the above code is executed, it produces the following output:

Output:
Example-1 Keyword arguments
Name: Gshan
Default Arguments:

  • In Python the default argument is an argument that takes a default value if no value is provided in the function call.
  • The following example uses default arguments, that prints default salary when no argument is passed.

Example:
def printinfo( name, salary = 3500):
print (“Name:”, name)
print (“Salary: “, salary)
return
printinfo(“Mani”)
When the above code is executed, it produces the following output

Output:
Name: Mani
Salary: 3500
When the above code is changed as print info(“Ram,”:2000) it produces the following

Output:
Name: Ram
Salary: 2000

Variable-Length Arguments:

  • In some instances, it is needed to pass more arguments that have already been specified.
  • These arguments are not specified in the function’s definition and an asterisk (*) is used to define such arguments.
  • These types of arguments are called Variable-Length arguments.

Syntax:
def function_name(*args):
function_body
return_statement

Example:
def printnos (*nos):
for n in nos:
print(n)
return
# now invoking the printnos() function
print (‘Printing two values’)
printnos (1,2)
Print (‘Printing three values’)
printnos (10,20,30)

Output:
Printing two values
1
2
Printing three values
10
20
30

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Tamilnadu State Board New Syllabus Samacheer Kalvi 12th Computer Science Guide Pdf Chapter 6 Control Structures Text Book Back Questions and Answers, Notes.

Tamilnadu Samacheer Kalvi 12th Computer Science Solutions Chapter 6 Control Structures

12th Computer Science Guide Control Structures Text Book Questions and Answers

I. Choose the best answer (1 Mark)

Question 1.
How many important control structures are there in Python?
a) 3
b) 4
c) 5
d) 6
Answer:
a) 3

Question 2.
elif can be considered to be abbreviation of
a) nested if
b) if..else
c) else if
d) if..elif
Answer:
c)else if

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 3.
What plays a vital role in Python programming?
a) Statements
b) Control
c) Structure
d) Indentation
Answer:
d) Indentation

Question 4.
Which statement is generally used as a placeholder?
a) continue
b) break
c) pass
d) goto
Answer:
c) pass

Question 5.
The condition in the if statement should be in the form of
a) Arithmetic or Relational expression
b) Arithmetic or Logical expression
c) Relational or Logical expression
d) Arithmetic
Answer:
c) Relational or Logical expression

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 6.
Which is the most comfortable loop?
a) do..while
b) while
c) for
d) if..elif
Answer:
c) for

Question 7.
What is the output of the following snippet?
i=l
while True:
if i%3 ==0:
break
print(i/end=”)
i +=1
a) 12
b) 123
c) 1234
d) 124
Answer:
a) 12

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 8.
What is the output of the following snippet?
T=1
while T:
print(True)
break
a) False
b) True
c) 0
d) no output
Answer:
b) True

Question 9.
Which amongst this is not a jump statement ?
a) for
b) goto
c) continue
d) break
Answer:
a) for

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 10.
Which punctuation should be used in the blank?
if < condition >
statements-block 1
else:
statements-block 2
a) ;
b) :
c) ::
d) !
Answer:
b) :

II. Answer the following questions (2 Marks)

Question 1.
List the control structures in Python.
Answer:
There are three important control structures

  1. Sequential
  2. Alternative or Branching
  3. Iterative or Looping

Question 2.
Write note on break statement.
Answer:

  • The break statement terminates the loop containing it.
  • Control of the program flows to the statement immediately after the body of the loop.
  • When the break statement is executed, the control flow of the program comes out of the loop and starts executing the segment of code after the loop structure.
  • If break statement is inside a nested loop (loop inside another loop), break will terminate the innermost loop.

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 3.
Write is the syntax of if..else statement
Answer:
Syntax:
if:
statements – block 1
else:
statements – block 2

Question 4.
Define control structure.
Answer:
A program statement that causes a jump of control from one part of the program to another is called a control structure or control statement.

Question 5.
Write note on range () in loop
Answer:
Usually in Python, for loop uses the range() function in the sequence to specify the initial, final and increment values. range() generates a list of values starting from start till stop – 1.

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

III. Answer the following questions (3 Marks)

Question 1.
Write a program to display
Answer:
A
AB
ABC
ABCD
ABCDE
For i in range (1,6,1):
ch=65
for j in range (ch,ch+i,1):
a=chr(j)
print (a, end =’ ‘)
print ()

Question 2.
Write note on if..else structure.
Answer:
The if-else statement provides control to check the true block as well as the false block. Following is the syntax of ‘if-else’ statement.
Syntax:
if:
statements – block 1
else:
statements – block 2

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 3.
Using if..else..elif statement write a suitable program to display largest of 3 numbers.
Answer:
a = int (input (“Enter number 1″)
b = int (input (” Enter number 2″)
c = int (input (” Enter number 3″)
if a > b and a > c:
put (” A is greatest”)
elif b > a and b > c:
print (“B is greatest”)
else:
print (“C is greatest”)

Question 4.
Write the syntax of while loop.
Answer:
The syntax of while loop in Python has the following syntax:
Syntax:
while:
statements block 1
[else:
statements block 2]

Question 5.
List the differences between break and continue statements.
Answer:

Break

Continue

Break statement terminates the loop containing it and control reaches after the body of the loop Continue statement skips the remaining part of a loop and start with next iteration.

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

IV. Answer the following questions (5 Marks)

Question 1.
Write a detail note on for loop
Answer:
for loop:

  • for loop is the most comfortable loop. It is also an entry check loop.
  • The condition is checked in the beginning and the body of the loop
    (statements-block 1) is executed if it is only True otherwise the loop is not executed.

Syntax:
for counter_variable in
sequence:
statements – block 1
[else: # optional block statements – block 2]

  • The counter, variable mentioned in the syntax is similar to the control variable that we used in the for loop of C++ and the sequence refers to the initial, final and increment value.
  • Usually in Python, for loop uses the range () function in the sequence to specify the initial, final and increment values, range () generates a list of values starting from start till stop-1.

The syntax of range() follows:
range (start, stop, [step])
Where,
start – refers to the initial value
stop – refers to the final value
step – refers to increment value,
this is optional part.

Examples for range():
range (1,30,1) – will start the range of values from 1 and end at 29 range (2,30,2) – will start the range of values from 2 and end at 28 range (30,3,-3) – will start the range of values from 30 and end at 6E range (20) – will consider this value 20 as the end value ( or upper limit) and starts the range count from 0 to 19 (remember always range () will work till stop -1 value only)

Example-Program:
#Program to illustrate the use of for loop – to print single digit even number
for i in range (2,10,2):
print (i, end=”)

Output:
2468
Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures 1

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 2.
Write a detail note on if..else..elif statement with suitable example.
Answer:

  • When we need to construct a chain of if statement(s) then ‘elif’ clause can be
    used instead of ‘else’.
    Syntax:
    if < condition -1>:
    statements-block 1
    elif< condition -2>:
    statements-block 2
    else:
    statements-block n
  • In the syntax of if..elif ..else mentioned above, condition -1 is tested if it is true then statements-block 1 is executed, otherwise, the control checks condition-Z, if it is true statements- block2 is executed and even if it fails statements-block n mentioned in else part is executed.
  • ‘elif’ clause combines if..else- if ..else statements to one if..elif … else, “elif’ can be considered to be abbreviation of ‘else if’. In an’if’ statement there is no limit of ‘elif’ clause that can be used, but an clause if used should be placed at the end.

Example:

# Program to illustrate the use of nested if statement
Average – Grade
> =80 and above A
> =70 and above B
> =60 and <70 C
> =50 and <60 D
Otherwise E

Example-program
m1 = int (input(“Enter mark in first subject:”))
m2 = int (input(” Enter mark in second subject:”))
avg = (ml+ml)/2
if avg> =80:
print (“Grade: A”)
elif avg> =70 and avg< 80:
print (“Grade: B”)
elif avg> =60 and avg< 60:
print (“Grade: C”)
elif avg> =50 and avg< 60: .
print (“Grade: D”)
else:
print(“Grade: E”)

Output 1:
Enter mark in first
subject: 34
Enter mark in second
subject: 78
Grade: D

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 3.
Write a program to display all 3 digit odd numbers.
Answer:
Odd Number (3 digits)
for a in range (100, 1000)
if a % 2 = = 1:
print b
Output:
101, 103, 105, 107, .. …… 997, 999

Question 4.
Write a program to display multiplication table for a given number.
Answer:
Coding:
num=int(input(“Display Multiplication Table of “))
for i in range(1,11):
print(i, x ,num, ‘=’, num*i)
Output:
Display Multiplication Table of 2
1 x 2 = 2
2 x 2 = 4
3 x 2 = 6
4 x 2 = 8
5 x 2 = 10
6 x 2 = 12
7 x 2 =14
8 x 2 = 16
9 x 2 =18
10 x 2 = 20
>>>

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

12th Computer Science Guide Control Structures Additional Questions and Answers

I. Choose the best answer ( I Mark)

Question 1.
Executing a set of statements multiple times are called…………………………..
(a) Iteration
(b) Looping
(c) Branching
(d) Both a and b
Answer:
(d) Both a and b

Question 2.
………… important control structures are available in python.
a) 2
b) 3
c) 4
d) many
Answer:
b) 3

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 3.
Identify which is not a control structure?
(a) Sequential
(b) Alternative
(c) Iterative
(d) Break
Answer:
(d) Break

Question 4.
To construct a chain of if statement, else can be replaced by
a) while
b) ifel
c) else if
d) elif
Answer:
d) elif

Question 5.
Branching statements are otherwise called……………………………
(a) Alternative
(b) Iterative
(c) Loop
(d) Sequential
Answer:
(a) Alternative

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 6.
Which statement is used to skip the remaining part of a loop and start with the next iteration?
a) continue
b) break
c) pass
d) condition
Answer:
a) continue

Question 7.
In the …………….. loop, the condition is any valid Boolean expression returning True or false.
a) if
b) else
c) elif
d) while
Answer:
d) while

Question 8.
How many blocks can be given in Nested if.. elif.. else statements?
(a) 1
(b) 2
(c) 3
(d) n
Answer:
(d) n

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 9.
A loop placed within another loop is called as …………… loop structure.
a) entry check
b) exit check
c) nested
d) conditional
Answer:
c) nested

Question 10.
What types of Expressions can be given in the while loop?
(a) Arithmetic
(b) Logical
(c) Relational
(d) Boolean
Answer:
(d) Boolean

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

II. Answer the following questions (2 and 3 Marks)

Question 1.
Write a note on sequential statements?
Answer:
A sequential statement is composed of a sequence of statements which are executed one after another. A code to print your name, address, and phone number is an example of a sequential statement.

Question 2.
Write the syntax of for loop.
Answer:
Syntax:
for counter_variable in sequence:
statements-block 1
[else: # optional block
statement-block 2]

Question 3.
Define loops?
Answer:
Iteration or loop are used in a situation when the user needs to execute a block of code several times or till the condition is satisfied. A loop statement allows executing a statement or group of statements multiple times.

Question 4.
What is meant by Nested loop structure?
Answer:

  • A loop placed within another loop is called a nested loop structure.
  • A while; within another while; for within another for;
  • For within while and while within for to construct nested loops.

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 5.
Give the syntax of range O in for loop?
Answer:
The syntax of range ( ) is as follows:
range (start, stop, [step] )
Where,
start – refers to the initial value
stop – refers to the final value
step – refers to increment value, this is an optional part.

Question 6.
Write a note on the pass statement.
Answer:

  • pass statement in Python programming is a null statement.
  • pass statement when executed by the interpreter it is completely ignored.
  • Nothing happens when the pass is executed, it results in no operation.

III. Answer the following questions (5 Marks)

Question 1.
Explain the types of alternative or branching statements provided by Python?
Answer:
The types of alternative or branching statements provided by Python are:

  1. Simple if statement
  2. if..else statement
  3. if..elif statement

1) Simple if statement
Simple if is the simplest of all decision-making statements. The condition should be in the form of relational or logical expression.
Syntax:
if:
statements-block1
Example:
x=int (input(“Enter your age :”))
if x > =18:
print (“You are; eligible for voting”)
Output:
Enter your age :34
You are eligible for voting

2) if..else statement
The if.. else statement provides control to check the true block as well as the false block. Following is the syntax of ‘if..else statement.
Syntax:
if:
statements-block 1
else:
statements-block 2
Example:
a = int(input(” Enter any number :”))
if a%2==0:
print (a, ” is an even number”) else:
print (a, ” is an odd number”)
Output 1:
Enter any number:56
56 is an even number
Output 2:
Enter any number:67
67 is an odd number
Flowchart- if..else statement Execution
Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures 2
3) Nested if..elif…else statement:

  • When we need to construct a chain of if statement(s) then ‘elif’ clause can be used instead of ‘else.
  • ‘elif’ clause combines if..else-if.. elsestatements to one if ..elif… else. elif can be considered to be abbreviation of else if.
  • In an ‘if statement there is no limit of ‘elif clause that can be used, but an ‘else clause if used should be placed at the end.

Syntax:
if<statements-block 1>:
elif :
statements-block 2
else:
statements-block n
Example:
a = int (input (“Enter number 1″)
b = int (input (” Enter number 2″)
c = int (input (” Enter number 3″)
if a > b and a > c:
put (” A is greatest”)
elif b > a and b > c:
print (“B is greatest”)
else:
print (“C is greatest”)

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 2.
Explain while loop with example.
Answer:

  • While loop belongs to entry check loop type, that is it is not executed even once
    if the condition is tested False in the beginning.
  • In the while loop, the condition is any valid Boolean expression returning
    True or False.
  • The else part of while is optional part of while. The statements blocki is kept
    executed till the condition is True.
  • If the else part is written, it is executed when the condition is tested False.

Syntax:
while< condition >:
statements block 1
[else:
statements block 2]
Flowchart-while loop execution:
Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures 3
Example:

i=10 # intializing part of the control variable
while (i<=15): # test condition
print (i,end=,\t/) # statements – block1
i=i+1 # Updation of the control variable

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 3.
Explain the Jump statement in python.
Answer:

  • The jump statement in Python is used to unconditionally transfer the control from one part of the program to another.
  • There are three keywords to achieve jump statements. in Python: break, continue, pass.

Flowchart -Use of break, continue statement in loop structure:

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures 4

  • break statement:
  • The break statement terminates the loop containing it.
  • Control of the program flows to the statement immediately after the body of the loop.
  • A while or for loop will iterate till the condition is tested false, but one can even transfer the control out of the loop (terminate) with help of a break statement.
  • When the break statement is executed, the control flow of the program comes out of the loop and starts executing the segment of code after the loop structure.
  • If the break statement is inside a nested loop (loop inside another loop), the break will terminate the innermost loop. Syntax for break statement:
    break
    Example: for word in “Jump Statement”:
    ifword = = “e”:
    break print (word, end= “)
    Output: Jump Stat
    Flowchart- Working of break statement:

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures 5
Working of break statement

continue statement: Continue statement unlike the break statement is used to skip the remaining part of a loop and start with the next iteration.

Syntax of continue statement:
continue Example:
for word in “Jump Statement”:
if word = = “e”:
continue print (word, end=”)
print (“\n End of the program”)

Output:
Jump Statement
End of the program

pass statement:

  • pass statement is generally used as a placeholder.
  • When we have a loop or function that is to be implemented in the future and not now, we cannot develop such functions or loops with empty body segments because the interpreter would raise an error.
  • So, to avoid this we can use a pass statement to construct a body that does nothing.

Syntax of pass statement:
pass

Example:
forval in “Computer”:
pass
print (“End of the loop, loop structure will be built in future”)
Output: End of the loop, loop structure will be built in future

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 4.
What kind of Nested ioop structure can be created?
Answer:

  • A loop placed within another loop is called a nested loop structure.
  • A while; within another while; for within another for;
  • for within while and while within to construct nested loops.

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures 6

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures 7

HANDS-ON PRACTICE

Question 1.
Write a program to check whether the given character is a vowel or not.
Answer:
Coding:
ch=input (“Enter a character :”)
# to check if the letter is vowel
if ch in (‘a’, ‘A’, e , E , i , I , o ,O , u’, ‘U’):
print (ch/ is a vowel’)
Output:
Enter a character:e
e is a vowel

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 2.
(i) Write a program to display all 3 digit even numbers.
(ii) Write the output for the following program.
Answer:
i=1
while (i<=6):
for j in range (1, i):
print(j, end=’\t’)
print (end=’ \ n’)
i+=1
i) Python Program:
for i in range(100,1000,2):
Print(i)
ii) Output: 1
1 2
1 2 3
1 2 3 4
1 2 3 4 5

Question 3.
Write a program to check if a number is Positive, Negative or zero.
Answer:
Coding:
num = float(input(” Enter a number: “))
if num > 0:
print(“Positive number”)
elifnum == 0:
print(“Zero”)
else:
print(“Negative number”)
Output:
Enter a number:5
Positive number

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 4.
Write a program to display Fibonacci series 0112345 (up to n terms)
Answer:
Coding:
Number = int(input(“\n Please Enter the Range Number: “))
i = 0
First_ Value = 0
Second-Value = 1
while(i < Number):
if(i <= 1):
Next = i else:
Next = First-Value + Second_Value
First_Value = Second_Value
Second_Value = Next
print(Next)
i = i + 1
Output:
Please Enter the Range Number: 4
0
1
1
2
3

Question 5.
Write a program to display sum of natural numbers, up to n.
Answer:
Coding:
number = int(input(“Please Enter any Number:”))
total = 0
for value in range(l, number + 1):
total = total + value
print(“The Sum of Natural Numbers is total)
Output:
Please Enter any Number:5
The Sum of Natural Numbers is : 15

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 6.
Write a program to check if the given number is a palindrome or not.
Answer:
Coding:
n=int(input(“Enter number:”))
temp=n
rev=0
while(n>0):
dig=n%10
rev=rev*10+dig
n=n//10
if(temp==rev):
print(“The number is a palindrome!”)
else:
print(“The number isn’t a palindrome!”)
Output:
isn’t a palindrome!

Question 7.
Write a program to print the following pattern
* * * * *
* * * *
* * *
* *
*
Answer:
Coding:
number = int(input(“Please Enter Pattern Number: “))
for i in range(number,0,-l):
for j in range(1,i+1,1):
print(“*”, end”)
print()
Output:
Please Enter Pattern Number:5
* * * * *
* * * *
* * *
* *
*

Samacheer Kalvi 12th Computer Science Guide Chapter 6 Control Structures

Question 8.
Write a program to check if the year is leap year or not.
Answer:
Coding:
def leap_year(y):
.’ if (y % 400 = = 0):
print(y, “is the leap year”)
elif(y%4 = = 0):
print(y, “is the leap year”)
else:
print(y, “is not a leap year”)
year = int(input(“Enter a year…”)
print(leap_year(year))
Output:
Enter a year… 2007
2007 is the leap year

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems

Tamilnadu State Board New Syllabus Samacheer Kalvi 12th Business Maths Guide Pdf Chapter 5 Numerical Methods Miscellaneous Problems Text Book Back Questions and Answers, Notes.

Tamilnadu Samacheer Kalvi 12th Business Maths Solutions Chapter 5 Numerical Methods Miscellaneous Problems

Question 1.
If f (x) = eax then show that f(0), Δf(0), Δ²f(0) are in G.P
Solution:
Given f(x) = eax
f(0) = e° = 1 ……… (1)
Δf(x) = ea(x+h) – eax
= e ax+ah – eax
= eax. eah – eax
= eax (eah – 1)
Δf(0) = e° (eah – 1)
= (eah – 1) …….. (2)
Δ²f(x)= Δ [Δf(x)]
= Δ [ea(x+h) – eax]
[ea(x+h+h) – ea(x+h)] – [ea(x+h) – eax]
= ea(x+2h) – ea(x+h) – ea(x+h) + eax
Δ²f(0) = Δ [Δf(x)]
= ea(2h) – ea(h) – ea(h) + e0
= e2ah – eah – eah + 1
= (eah)² – 2eah + 1
= [eah – 1]² ………… (3)
from (1), (2) & (3)
[t2]² =[Δf(0)]² = (eah – 1)²
t1 × t3 = f(0) × Δ²f(0)
= (1)(eah – 1)² = (eah – 1)²
⇒ [Δf(0)]² = f(0) × Δ²f(0)
∴ f(0), Δf(0), Δ²f(0) an is G.P.

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems

Question 2.
Prove that
(i) (1 + Δ) (1 – ∇) = 1
(ii) Δ∇ = Δ – ∇
(iii) EV = Δ = ∇E
Solution:
(i) LHS = (1 + Δ) (1 – ∇)
= (E) (E-1) = E1-1
= E° = 1
= RHS
Hence proved.

(ii) LHS = Δ∇
= (E – 1)(1 – E-1)
= E – EE-1 + E-1
= E – 1 – 1 – E-1
= E – 2 – E-1 ………… (1)
RHS = Δ – ∇
= (E – 1) -(1 – E-1)
= E – 1 – 1 + E-1
= E – 2 + E-1 ………. (2)
from (1) & (2) LHS = RHS
Hence proved.

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems

(iii) E∇ = EE-1Δ [∵ ∇ = E-1Δ]
= Δ ……… (1)
∇E = E-1 ΔE
= E-1
= Δ ………. (2)
from (1) (2)
E∇ = Δ = ∇E

Question 3.
A second degree polynomial passes though the point (1, -1) (2, -1) (3, 1) (4, 5). Find the polynomial.
Solution:
Points are (1, -1), (2, -1), (3, 1) and (4, 5)
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 1
we will use Newton’s backward interpolation formula to find the polynomial.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 2
= 5 + (x – 4) (4) + (x – 4) (x – 3) + 0
= 5 + 4x – 16 + x² – 7x + 12
y(x) = x² – 3x + 1

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems

Question 4.
Find the missing figures in the following table
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 3
Solution:
Here y0 = 7; y1 = 11; y2 = ?; y3 = 18; y4 = ?; y5 = 32
Since only four values of f(x) are given, the polynomial which fits the data is of degree three. Hence fourth differences are zeros.
Δ4yk = 0
(ie) (E – 1)4 yk = 0
(i.e) (E4 – 4E³ + 6E² – 4E + 1)yk = 0 ……….. (1)
Put k = 0 in (1)
(E4 – 4E³ + 6E² – 4E + 1)y0 = 0
E4 y0 – 4E3 y0 + 6E² y0 – 4E y0 + y0 = 0
y4 – 4y3 + 6y2 – 4y1 + y0 = 0
y4 – 4(18) + 6y2 – 4(11) + 7 = 0
y4 – 72 + 6y2 – 44 + 7 = 0
y4 + 6y2 = 109
(2)
Put k = 1 in (1)
(E4 – 4E3 + 6E² – 4E + 1)y1 = 0
[E4 y1 – 4E y1 + 6E² y1 – 4Ey1 + y] = 0
y5 – 4y4 + 6y3 – 4y2 + y1 = 0
32 – 4 (y4) + 6(18) — 4(y2) + 11 = 0
32 – 4y4 + 108 – 4y2 + 11 = 0
-4y4 – 4y2 + 151 = 0
4y4 + 4y2 = 151 ,……. (3)
Solving equation (1) & (2)
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 4
Substitute y2 = 14.25 in eqn (1)
y4 + 6(14.25) = 109
y4 + 25.50 = 109
y4 = 109 – 85.5
∴ y4 = 23.5
∴ Required two missing values are 14.25 and 23.5.

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems

Question 5.
Find f (0.5) if f(-1) = 202, f(0) = 175, f(1) = 82 and f(2) = 55
Solution:
From the given data
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 5
Here we have to apply Newton’s forward interpolation formula, since the value of f(x) is required near the beginning of the table.
y(x= x0+nh) =f(x0) + \(\frac { n }{1!}\) Δf(x0) + \(\frac { n(n-1) }{2!}\) Δ²f(x0) + \(\frac { n(n-1)(n-2) }{3!}\) Δ³f(x0) + ………
Given:
x = 0.5 and h = 1
x0 + nh = x
-1 + n(1) = 0.5
n = 1 + 0.5
∴ n = 1.5
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 6
= 202 – 40.5 – 24.75 – 8.25
= 202 – 73.5
f(0.5) = 128.5

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems

Question 6.
From the following data find y at x = 43 and x = 84
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 7
Solution:
To find y at x = 43
Since the value of y is required near the beginning of the table, we use the Newton’s forward interpolation formula.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 8
= 184 + (0.3) (20) + (0.3) (-0.7)
= 184 + 6.0 – 0.21
= 190 + 0.21
y(x=43) = 189.79
To find y at x = 84
Since the value of y is required at the end of the table, we apply backward interpolation formula.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 9
xn + nh = x
90 + n(10) = 84
10n = 84 – 90
10n = -6
∴ n = -0.6
y(x=84) = 304 + \(\frac { (0.6) }{1!}\) (28) + \(\frac {(0.6)(-0.6 + 1) }{2!}\)(2) +
= 304 + (0.6) (28) + \(\frac { (-0.6)(0.4) }{2}\) + 2
= 304 – 16.8 – 0.24
= 304 – 17.04
= 286.96

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems

Question 7.
The area A of circle of diameter ‘d’ is given for the following values
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 10
Find the approximate values for the areas of circles of diameter 82 and 91 respectively.
Solution:
To find A at D = 82
Since the value of A is required near the beginning of the table. We use the Newton’s forward interpolation formula.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 11
= 5026 + 259.2 – 4.8 – 0.128 – 0.1664
= 5285.2 – 5.0944
= 5280.1056
A = 5280.11
To find Δ at D = 91
Since the value of A is required near the beginning of the table. We use the Newton’s forward interpolation formula.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 12
= 7854 – 1378.8 + 28.8 + 0.096 + 0.0576
= 7882.9536 – 1378.8
= 6504.1536
= 6504.15

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems

Question 8.
If u0 = 560, u1 = 556, u2 = 520, u4 = 385, show that u3 = 465
Solution:
U0 = 560; U1 = 556; U2 = 520; U4 = 385
Since only four values of U are given, the polynomial which fits the data is of degree three. Hence fourth differences are zeros.
Δ4U0
(E – 1)4 U0 = 0
⇒ (E4 – 4E³ + 6E² – 4E + 1) U0 = 0
⇒ E4U0 – 4E³U0 + 6E²U0 – 4EU0 + U0 = 0
U4 – 4U3 + 6U2 – 4U1 + U0 = 0
385 – 4(U3) + 6 (520) – 4 (556) + 560 = 0
385 – 4(U3) + 3120 – 2224 + 560 = 0
1841 – 4U3 = 0
4U3 = 1841 ⇒ U3 = \(\frac { 1841 }{4}\)
U3 = 460.25

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems

Question 9.
From the following table obtain a polynomial of degree y in x
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 13
Solution:
We will use Newton’s backward interpolation formula to find the polynomial.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 14
To find y in terms of x
xn + nh = x
5 + n(1) = x
∴ n = x – 5
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 15
= 1 + 2x – 10 + 2 (x² – 9x + 20) + \(\frac { 4 }{3}\) (x – 5) (x² – 7x + 12) + \(\frac { 2 }{3}\)(x² – 9x + 20)(x² – 5x + 6)
= 1 + 2x – 10 + 2x² – 18x + 40 + \(\frac { 4 }{3}\)
[x³ – 7x² + 12x – 5x² + 35x – 60] + \(\frac { 2 }{3}\) [x4 – 5x³ + 6x² – 9x³ + 45x² – 54x + 20x² – 100x + 120]
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 16

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems

Question 10.
Using Lagrange’s interpolation formula find a polynominal which passes through the points (0, -12), (1, 0), (3, 6) and (4, 12).
Solution:
We can construct a table using the given points.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 17
Here x0 = 0; x1 = 1; x2 = 3; x3 = 4,
y0 = -12; y1 = 0; y2 = 6; y3 = 12
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems 18
= (x³ – 7x² + 12x – x² + 7x – 12) – (x³ – 5x² + 4x) + (x³ – 4x² + 3x)
= (x³ – 8x² + 19x – 12) – (x³ – 5x² + 4x) + (x³ – 4x² + 3x)
= x³ – 8x² + 19x – 12 – x³ + 5x² – 4x + x³ – 4x² + 3x
∴ y = x³ – 7x² + 18x – 12

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Miscellaneous Problems

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Tamilnadu State Board New Syllabus Samacheer Kalvi 12th Computer Science Guide Pdf Chapter 5 Python -Variables and Operators Text Book Back Questions and Answers, Notes.

Tamilnadu Samacheer Kalvi 12th Computer Science Solutions Chapter 5 Python -Variables and Operators

12th Computer Science Guide Python -Variables and Operators Text Book Questions and Answers

I. Choose the best answer (1 Marks)

Question 1.
Who developed Python ?
a) Ritche
b) Guido Van Rossum
c) Bill Gates
d) Sunder Pitchai
Answer:
b) Guido Van Rossum

Question 2.
The Python prompt indicates that Interpreter is ready to accept instruction.
a) > > >
b) < < <
c) #
d) < <
Answer:
a) > > >

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 3.
Which of the following shortcut is used to create a new Python Program?
a) Ctrl + C
b) Ctrl + F
c) Ctrl + B
d) Ctrl + N
Answer:
d) Ctrl + N

Question 4.
Which of the following character is used to give comments in Python Program?
a) #
b) &
c) @
d) $
Answer:
a) #

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 5.
This symbol is used to print more than one item on a single line.
a) Semicolon(;)
b) Dollor($)
c) commaQ
d) Colon(:)
Answer:
c) commaQ

Question 6.
Which of the following is not a token?
a) Interpreter
b) Identifiers
c) Keyword
d) Operators
Answer:
a) Interpreter

Question 7.
Which of the following is not a Keyword in Python?
a) break
b) while
c) continue
d) operators
Answer:
d) operators

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 8.
Which operator is also called a Comparative operator?
a) Arithmetic
b). Relational
c) Logical
d) Assignment
Answer:
b) Relational

Question 9.
Which of the following is not a Logical operator?
a) and
b) or
c) not
d) Assignment
Answer:
d) Assignment

Question 10.
Which operator is also called a Conditional operator?
a) Ternary
b) Relational
c) Logical
d) Assignment
Answer:
a) Ternary

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

II. Answer the following questions (2 Marks)

Question 1.
What are the different modes that can be used to test Python Program?
Answer:
In Python, programs can be written in two ways namely Interactive mode and Script mode. The Interactive mode allows us to write codes in Python command prompt (>>>) whereas in script mode programs can be written and stored as separate file with the extension .py and executed. Script mode is used to create and edit python source file.

Question 2.
Write short notes on Tokens.
Answer:
Python breaks each logical line into a sequence of elementary lexical components known as Tokens.
The normal token types are

  1. Identifiers
  2. Keywords
  3. Operators
  4. Delimiters
  5. Literals

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 3.
What are the different operators that can be used in Python?
Answer:
In computer programming languages operators are special symbols which represent computations, conditional matching etc. The value of an operator used is called operands. Operators are categorized as Arithmetic, Relational, Logical, Assignment etc.

Question 4.
What is a literal? Explain the types of literals?
Answer:

  • Literal is raw data given in a variable or constant.
  • In Python, there are various types of literals.
  1. Numeric
  2. String
  3. Boolean

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 5.
Write short notes on Exponent data.
Answer:
An Exponent data contains decimal digit part, decimal point, exponent part followed by one or more digits.
12.E04, 24.e04 # Exponent data

III. Answer the following questions (3 Marks)

Question 1.
Write short notes on the Arithmetic operator with examples.
Answer:

  • An arithmetic operator is a mathematical operator that takes two operands and performs a calculation on them.
  • They are used for simple arithmetic.
  • Most computer languages contain a set of such operators that can be used within equations to perform different types of sequential calculations.
  • Python supports the following Arithmetic operators.
Operator-Operation Examples Result
Assume a=100 and b=10 Evaluate the following expressions
+ (Addition) > > > a+b 110
– (Subtraction) > > > a-b 90
* (Multiplication) > > > a*b 1000
/ (Division) > > > a/b 10.0
% (Modulus) > > > a% 30 10
** (Exponent) > > > a**2 10000
/ / (Floor Division) > > > a// 30 (Integer Division) 3

Question 2.
What are the assignment operators that can be used in Python?
Answer:

  • In Python,= is a simple assignment operator to assign values to variables.
  • There are various compound operators in Python like +=, -=, *=, /=,%=, **= and / / = are also available.
  • Let = 5 and = 10 assigns the values 5 to and 10 these two assignment statements can also be given a =5 that assigns the values 5 and 10 on the right to the variables a and b respectively.
Operator Description Example
Assume x=10
= Assigns right side operands to left variable »> x=10

»> b=”Computer”

+= Added and assign back the result to left operand i.e. x=30 »> x+=20 # x=x+20
= Subtracted and assign back the result to left operand i.e. x=25 >>> x-=5 # x=x-5

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 3.
Explain the Ternary operator with examples.
Answer:
Conditional operator:
Ternary operator is also known as a conditional operator that evaluates something based on a condition being true or false. It simply allows testing a condition in a single line replacing the multiline if-else making the code compact.
The Syntax conditional operator is,
Variable Name = [on – true] if [Test expression] else [on – false]
Example:
min = 50 if 49 < 50 else 70 # min = 50 min = 50 if 49 > 50 else 70 # min = 70

Question 4.
Write short notes on Escape sequences with examples.
Answer:

  • In Python strings, the backslash “\” is a special character, also called the “escape” character.
  • It is used in representing certain whitespace characters: “t” is a tab, “\n\” is a new line, and “\r” is a carriage return.
  • For example to print the message “It’s raining”, the Python command is > > > print (“It \ ‘s raining”)
  • output:
    It’s raining
Escape sequence character Description Example Output
w Backslash >>> print(“\\test”) \test
Y Single-quote »> print(“Doesn\’t”) Doesn’t
\” Double-quote »> print(“\”Python\””) “Python”
\n New line pr in t (” Python “,” \ n”,” Lang..”) Python Lang..
\t Tab print(“Python”,”\t”,”Lang..”) Python Lang..

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 5.
What are string literals? Explain.
Answer:
String Literals:
In Python, a string literal is a sequence of characters surrounded by quotes. Python supports single, double and triple quotes for a string. A character literal is a single character surrounded by single or double-quotes. The value with triple – the quote is used to give multi-line string literal.
Strings = “This is Python”
char = “C”
multiline _ str = “This is a multiline string with more than one line code”.

IV. Answer the following questions (5 Marks)

Question 1.
Describe in detail the procedure Script mode programming
Answer:

  • Basically, a script is a text file containing the Python statements.
  • Python Scripts are reusable code.
  • Once the script is created, it can be executed again and again without retyping.
  • The Scripts are editable

Creating Scripts in Python:

  • Choose File → New File or press Ctrl + N in the Python shell window.
  • An untitled blank script text editor will be displayed on the screen.
  • Type the code in Script editor
    a=100
    b=350
    c=a+b
    print(“The Sum=”,c)

Saving Python Script:

  • Choose File →Save or press Ctrl+S
  • Now, Save As dialog box appears on the screen
  • In the Save As dialog box, select the location where you want to save your Python code, and type the File name box Python files are by default saved with extension by Thus, while creating Python scripts using Python Script editor, no need to specify the file extension.
  • Finally, ‘click Save button to save your Python script.

Executing Python Script:

  • Choose Run-Run Module or Press F5
  • If code has any error, it will be shown in red color in the IDLE window,, and Python describes the type of error occurred. To correct the errors, go back to Script editor, make corrections, save the file using Ctrl + S or File→Save and execute it again.
  • For all error-free code, the output will appear in the IDLE window of Python.

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 2.
Explain input () and print() functions with examples.
Answer:
input () function:
In Python input() function is used to accept data as input at run time.
Syntax:
Variable = input (“prompt string”)

  • where, prompt string in the syntax is a statement or message to the user, to know what input can be given.
  • The input() takes whatever is typed from the keyboard and stores the entered data in the given variable.
  • If prompt string is not given in input() no message is displayed on the screen, thus, the user will not know what is to be typed as input

Example:
> > > city=input(“Enter Your City: “)
Enter Your City: Madurai
> > > print(“I am from “, city)
I am from Madurai

  • The input () accepts all data as string or characters but not as numbers.
  • If a numerical value is entered, the input values should be explicitly converted into numeric data type.
  • The int( ) function is used to convert string data as integer data explicitly.

Example:
x= int (input(“Enter Number 1: “))
y = int (input(“Enter Number 2: “))
print (“The sum =”, x+y)
Output
Enter Number 1: 34
Enter Number 2: 56
The sum = 90
print () function :
In Python, the print() function is used to display result on the screen. The syntax for print() is as follows:

Syntax:
print (“string to be displayed as output” )
print (variable)
print (“String to be displayed as output variable)
print (“String 1 “, variable, “String 2′”,variable, “String 3” )….)

Example
> > > print (“Welcome to Python Programming”)
Welcome to
Python Programming
> > > x= 5
> > > y= 6
> > > z=x+y
> > > print (z)
11
> > > print (“The sum =”,z)
The sum=11
> > > print (“The sum of”,x, “and “, y, “is “,z)
The sum of 5 and 6 is 11

  • The print( ) evaluates the expressions before printing it on the monitor
  • The print( ) displays an entire statement which specified within print ( )
  • Comma (,) is used as a separator in print more than one time

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 3.
Discuss in detail about Tokens in Python
Answer:
Python breaks each logical line into a sequence of elementary lexical components known as Token.
The normal token types are

  1. Identifiers
  2. Keywords
  3. Operators
  4. Delimiters and
  5. Literals.

Identifiers:

  • An Identifier is a name used to identify a variable, function, class, module or object.
  • An identifier must start with an alphabet
    (A..Z or a..z) or underscore (_). Identifiers may contain digits (0 .. 9). „
  • Python identifiers are case sensitive i.e. uppercase and lowercase letters are distinct. Identifiers must not be a python keyword.
  • Python does not allow punctuation characters such as %,$, @, etc., within identifiers.

Keywords:
Keywords are special words used by Python interpreters to recognize the structure of the program. As these words have specific meanings for interpreters, they cannot be used for any other purpose.

Operators:

  • In computer programming languages operators are special symbols which represent computations, conditional matching, etc.
  • The value of an operator used is called operands.
  • Operators are categorized as Arithmetic, Relational, Logical, Assignment, etc. Value and variables when used with the operator are known as operands

Delimiters:
Python uses the symbols and symbol combinations as delimiters in expressions, lists, dictionaries, and strings
Following are the delimiters knew as operands.
Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators 1
Literals:
Literal is raw data given in a variable or constant. In Python, there are various types of literals.

  • Numeric
  • String
  • Boolean

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

12th Computer Science Guide Python -Variables and Operators Additional Questions and Answers

I. Choose the best answer (1 Mark)

Question 1.
Python language was released in the year
a) 1992
b) 1994
c) 1991
d) 2001
Answer:
c) 1991

Question 2.
CWI means ……………………………
Answer:
Centrum Wiskunde & Information

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 3.
In Python, How many ways programs can be written?
a) 4
b) 2
c) 3 ‘
d) many
Answer:
b) 2

Question 4.
Find the wrong statement from the following.
(a) Python supports procedural approaches
(b) Python supports object-oriented approaches
(c) Python is a DBMS tool
Answer:
(c) Python is a DBMS tool

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 5.
Which mode displays the python code result immediately?
a) Compiler
b) Script
c) Interactive
d) program
Answer:
c) Interactive

Question 6.
Which of the following command is used to execute the Python script?
a) Run → Python Module
b) File → Run Module
c) Run → Module Fun
d) Run → Run Module
Answer:
d) Run → Run Module

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 7.
The extension for the python file is ……………………………
(a) .pyt
(b) .pt
(c) .py
(d) .pyth
Answer:
(c) .py

Question 8.
Which operator replaces multiline if-else in python?
a) Local
b) Conditional
c) Relational
d) Assignment
Answer:
b) Conditional

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 9.
Which of the following is a sequence of characters surrounded by quotes?
a) Complex
b) String literal
c) Boolean
d) Octal
Answer:
b) String literal

Question 10.
What does prompt (>>>) indicator?
(a) Compiler is ready to debug
(b) Results are ready
(c) Waiting for the Input data
(d) Interpreter is ready to accept Instructions
Answer:
(d) Interpreter is ready to accept Instructions

Question 11.
In Python shell window opened by pressing.
a) Alt + N
b) Shift + N
c) Ctrl + N
d) Ctrl + Shift +N
Answer:
c) Ctrl + N

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 12.
In Python, comments begin with …………..
a) /
b) #
c)\
d) //
Answer:
b) #

Question 13.
Which command is selected from the File menu creates a new script text editor?
(a) New
(b) New file
(c) New editor
(d) New Script file
Answer:
(b) New file

Question 14.
Python uses the symbols and symbol combinations as ……………. in expressions
a) literals
b) keywords
c) delimiters
d) identifiers
Answer:
c) delimiters

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 15.
All data values in Python are ……………
a) class
b) objects
c) type
d) function
Answer:
b) objects

Question 16.
…………………………… command is used to execute python script?
(a) Run
(b) Compile
(c) Run ? Run Module
(d) Compile ? Compile Run
Answer:
(c) Run ? Run Module

Question 17.
Octal integer uses …………………………… to denote octal digits
(a) OX
(b) O
(c) OC
(d) Od
Answer:
(b) O

Question 18.
Find the hexadecimal Integer.
(a) 0102
(b) 0876
(c) 0432
(d) 0X102
Answer:
(d) 0X102

Question 19.
How many floating-point values are there is a complex number?
(a) 1
(b) 2
(c) 3
(d) 4
Answer:
(b) 2

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

II. Answer the following questions (2 and 3 Marks)

Question 1.
Write a note on keywords. Give examples?
Answer:
Keywords are special words used by Python interpreters to recognize the structure of the program. As these words have specific meanings for interpreters, they cannot be used for any other purpose. Eg, While, if.

Question 2.
What are keywords? Name any four keywords in Python.
Answer:
Keywords are special words that are used by Python interpreters to recognize the structure of the program.
Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators 2

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 3.
Write a note on the relational or comparative operator.
Answer:

  • A Relational operator is also called a Comparative operator which checks the relationship between two operands.
  • If the relation is true, it returns True otherwise it returns False.

Question 4.
Write a short note on the comment statement.
Answer:

  • In Python, comments begin with hash symbol (#).
  • The lines that begins with # are considered as comments and ignored by the Python interpreter.
  • Comments may be single line or no multilines.
  • The multiline comments should be enclosed within a set of # as given below.
    # It is Single line Comment
    # It is multiline comment which contains more than one line #

Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

Question 5.
What are the key features of python?
Answer:
Key features of Python:
It is a general-purpose programming language which can be used for both scientific and non – scientific programming
It is a platform-independent programming language.
The programs written in Python are easily readable and understandable

Question 6.
What are the uses of the logical operators? Name the operators.
Answer:

  • In python, Logical operators are used to performing logical operations on the given relational expressions.
  • There are three logical operators they are and or not.
  • Samacheer Kalvi 12th Computer Science Guide Chapter 5 Python -Variables and Operators

III. Answer the following questions (5 Marks)

Question 1.
Explain data types in python?
Answer:
Python Data types:
All data values in Python are objects and each object or value has a type. Python has Built-in or Fundamental data types such as Numbers, String, Boolean, tuples, lists, and dictionaries.

Number Data type:
The built-in number objects in Python supports integers, floating-point numbers, and complex numbers.
Integer Data can be decimal, octal, or hexadecimal. Octal integers use O (both upper and lower case) to denote octal digits and hexadecimal integers use OX (both upper and lower case) and L (only upper case) to denote long integers.
Example:
102, 4567, 567 # Decimal integers
0102, o876, 0432 # Octal integers
0X102, oX876, 0X432 # Hexadecimal integers
34L, 523L # Long decimal integers
A floating-point data is represented by a sequence of decimal digits that includes a decimal point. An Exponent data contains decimal digit part, decimal point, exponent part followed by one or more digits.
Example :
123.34, 456.23, 156.23 # Floating point data
12.E04, 24.e04 # Exponent data
A complex number is made up of two floating-point values, one each for the real and imaginary parts.

Boolean Data type:
A Boolean data can have any of the two values: True or False.

Example:
Bool_varl = True
Bool_var2 = False

String Data type:
String data can be enclosed with a single quote or double quote or triple quote.

Example:
Char_data = ‘A’
String_data = “Computer Science”
Multiline_data= “““String data can be enclosed with single quote or double quote or triple quote.”””

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Tamilnadu State Board New Syllabus Samacheer Kalvi 12th Computer Science Guide Pdf Chapter 4 Algorithmic Strategies Text Book Back Questions and Answers, Notes.

Tamilnadu Samacheer Kalvi 12th Computer Science Solutions Chapter 4 Algorithmic Strategies

12th Computer Science Guide Algorithmic Strategies Text Book Questions and Answers

I. Choose the best answer (1 Mark)

Question 1.
The word comes from the name of a Persian mathematician Abu Ja’far Mohammed ibn-i Musa al Khwarizmi is called?
a) Flowchart
b) Flow
c) Algorithm
d) Syntax
Answer:
c) Algorithm

Question 2.
From the following sorting algorithms which algorithm needs the minimum number of swaps?
a) Bubble sort
b) Quick sort
c) Merge sort
d) Selection sort
Answer:
d) Selection sort

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 3.
Two main measures for the efficiency of an algorithm are
a) Processor and memory
b) Complexity and capacity
c) Time and space
d) Data and space
Answer:
c) Time and space

Question 4.
The complexity of linear search algorithm is
a) O(n)
b) O(log n)
c) O(n2)
d) O(n log n)
Answer:
a) O(n)

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 5.
From the following sorting algorithms which has the lowest worst-case complexity?
a) Bubble sort
b) Quick sort
c) Merge sort
d) Selection sort
Answer:
c) Merge sort

Question 6.
Which of the following is not a stable sorting algorithm?
a) Insertion sort
b) Selection sort
c) Bubble sort
d) Merge sort
Answer:
b) Selection sort

Question 7.
Time Complexity of bubble sort in best case is
a) θ (n)
b) θ (nlogn)
c) θ (n2)
d) θ n(logn)2)
Answer:
a) θ (n)

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 8.
The Θ notation in asymptotic evaluation represents
a) Base case
b) Average case
c) Worst case
d) NULL case
Answer:
b) Average case

Question 9.
If a problem can be broken into sub problems which are reused several times, the problem possesses which property?
a) Overlapping sub problems
b) Optimal substructure
c) Memoization
d) Greedy
Answer:
a) Overlapping sub problems

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 10.
In dynamic programming, the technique of storing the previously calculated values is called ?
a) Saving value property
b) Storing value property
c) Memoization
d) Mapping
Answer:
c) Memoization

II. Answer the following questions (2 Marks)

Question 1.
What is an Algorithm?
Answer:
An algorithm is a finite set of instructions to accomplish a particular task. It is a step-by-step procedure for solving a given problem. An algorithm can be implemented in any suitable programming language.

Question 2.
Define Pseudocode
Answer:

  • Pseudocode is a notation similar to programming languages.
  • Pseudocode is a mix of programming-language-like constructs and plain English.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 3.
Who is an Algorist?
Answer:
A person skilled in the design of algorithms is called Agorist.

Question 4.
What is Sorting?
Answer:
Sorting is a method of arranging a group of items in ascending or descending order. Various sorting techniques in algorithms are Bubble Sort, Quick Sort, Heap Sort, Selection Sort, Insertion Sort.

Question 5.
What is searching? Write its types.
Answer:

  1. Searching is a process of finding a particular element present in given set of elements.
  2. Some of the searching types are:

Linear Search
Binary Search.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

III. Answer the following questions (3 Marks)

Question 1.
List the characteristics of an algorithm
Answer:
Input, Output, Finiteness, Definiteness, Effectiveness, Correctness, Simplicity, Unambiguous, Feasibility, Portable and Independent.

Question 2.
Discuss Algorithmic complexity and its types
Answer:

  • The complexity of an algorithm f (n) gives the running time and/or the storage space required by the algorithm in terms of n as the size of input data.
  • Time Complexity: The Time complexity of an algorithm is given by the number of steps taken by the algorithm to complete the process.
  • Space Complexity: Space complexity of an algorithm is the amount of memory required to run to its completion.

The space required by an algorithm is equal to the sum of the following two components:

  • A fixed part is defined as the total space required to store certain data and variables for an algorithm.
  • Example: simple variables and constants used in an algorithm.
  • A variable part is defined as the total space required by variables, which sizes depends on the problem and its iteration.
  • Example: recursion used to calculate factorial of a given value n.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 3.
What are the factors that influence time and space complexity?
Answer:
Time Complexity:
The Time complexity of an algorithm is given by the number of steps taken by the algorithm to complete the process.

Space Complexity:
Space complexity of an algorithm is the amount of memory required to run to its completion. The space required by an algorithm is equal to the sum of the following two components:

A fixed part is defined as the total space required to store certain data and variables for an algorithm. For example, simple variables and constants used in an algorithm. A variable part is defined as the total space required by variables, which sizes depends on the problem and its iteration. For example, recursion used to calculate the factorial of a given value n.

Question 4.
Write a note on Asymptotic notation
Answer:

  • Asymptotic Notations are languages that use meaningful statements about time and space complexity.
  • The following three asymptotic notations are mostly used to represent time complexity of algorithms:

Big O:
Big O is often used to describe the worst -case of an algorithm.

Big Ω:

  • Big O mega is the reverse Big O if Bi O is used to describe the upper bound (worst – case) of an asymptotic function,
  • Big O mega is used to describe the lower bound (best-case).

Big Θ:
When an algorithm has complexity with lower bound = upper bound, say that an algorithm has a complexity 0 (n log n) and Ω (n log n), it actually has the complexity Θ (n log n), which means the running time of that algorithm always falls in n log n in the best-case and worst-case.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 5.
What do you understand by Dynamic programming?
Answer:
Dynamic programming is an algorithmic design method that can be used when the solution to a problem can be viewed as the result of a sequence of decisions. The dynamic programming approach is similar to divide and conquer. The given problem is divided into smaller and yet smaller possible subproblems.

IV. Answer the following questions (5 Marks)

Question 1.
Explain the characteristics of an algorithm.
Answer:

Input Zero or more quantities to be supplied.
Output At least one quantity is produced.
Finiteness Algorithms must terminate after a finite number of steps.
Definiteness all operations should be well defined. For example, operations involving division by zero or taking square root for negative numbers are unacceptable.
Effectiveness Every instruction must be carried out effectively.
Correctness The algorithms should be error-free.
Simplicity Easy to implement.
Unambiguous The algorithm should be clear and unambiguous. Each of its steps and their inputs/outputs should be clear and must lead to only one meaning.
Feasibility Should be feasible with the available resources.
Portable An algorithm should be generic, independent of any programming language or an operating system able to handle all range of inputs.
Independent An algorithm should have step-by-step directions, which should be independent of any programming code.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 2.
Discuss Linear search algorithm
Answer:

  • Linear search also called sequential search is a sequential method for finding a particular value in a list.
  • This method checks the search element with each element in sequence until the desired element is found or the list is exhausted. In this searching algorithm, list need not be ordered.

Pseudocode:

  • Traverse the array using for loop
  • In every iteration, compare the target search key value with the current value of the list.
  • If the values match, display the current index and value of the array.
  • If the values do not match, move on to the next array element.
  • If no match is found, display the search element not found.

Example:

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies 1

  • To search the number 25 in the array given below, a linear search will go step by step in a sequential order starting from the first element in the given array if the search element is found that index is returned otherwise the search is continued till the last index of the array.
  • In this example number 25 is found at index number 3.

Question 3.
What is Binary search? Discuss with example
Answer:
Binary Search:

  • Binary search also called a half-interval search algorithm.
  • It finds the position of a search element within a sorted array.
  • The binary search algorithm can be done as a dividend- and -conquer search algorithm and executes in logarithmic time.

Example:

  • List of elements in an array must be sorted first for Binary search. The following example describes the step by step operation of binary search.
  • Consider the following array of elements, the array is being sorted so it enables to do the binary search algorithm.
    Let us assume that the search element is 60 and we need to search the location or index of search element 60 using binary search.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies 2

  • First ‘we find index of middle element of the array by using this formula:
    mid = low + (high – low)/2
  • Here it is, 0+(9 – 0)/2 = 4 (fractional part ignored)v So, 4 is the mid value of the array.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies 3

  • Now compare the search element with the value stored at mid-value location 4. The value stored at location or index 4 is 50, which is not match with search element. As the search value 60 is greater than 50.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies 4

  • Now we change our low to mid + land find the new mid-value again using the formula.
    low to mid + 1
    mid = low + (high -low) / 2
  • Our new mid is 7 now. We compare the value stored at location 7 with our target value 31.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies 5

  • The value stored at location or index 7 is not a match with search element, rather it is more than what we are looking for. So, the search element must be in the lower part from the current mid-value location

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies 6

  • The search element still not found. Hence, we calculated the mid again by using the formula.
    high = mid – 1
    mid = low + (high – low)/2
    Now the mid-value is 5.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies 7

  • Now we compare the value stored at location 5 with our search element. We found that it is a match.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies 8

  • We can conclude that the search element 60 is found at the location or index 5.
  • For example, if we take the search element as 95, For this value this binary search algorithm returns the unsuccessful result.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 4.
Explain the Bubble sort algorithm with example
Answer:
Bubble sort:

  • Bubble sort algorithm simple sorting algorithm.
  • The algorithm starts at the beginning of the I list of values stored in an array.
  • It compares each pair of adjacent elements and swaps them if they are in the unsorted order.
  • This comparison and passed to be continued until no swaps are needed, which indicates that the list of values stored in an array is sorted.
  • The algorithm is a comparison sort, is named for the way smaller elements “bubble” to the top of the list.
  • Although the algorithm is simple, it is too slow and less efficient when compared to insertion sort and other sorting methods.
  • Assume list is an array of n elements. The swap function swaps the values of the given array elements.

Pseudocode:

  • Start with the first element i.e., index = 0, compare the current element with the next element of the array.
  • If the current element is greater than the next element of the array, swap them.
    If the current element is less than the next or right side of the element, move to the next element. Go to Step 1 and repeat until the end of the index is reached.

Let’s consider an array with values {15, 11, 16, 12, 14, 13} Below, we have a pictorial representation of how bubble sort will sort the given array.
Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies 9
The above pictorial example is for iteration-d. Similarly, remaining iteration can be done. The final iteration will give the sorted array. At the end of all the iterations we will get the sorted values in an array as given below:
Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies 10

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 5.
Explain the concept of dynamic programming with a suitable example.
Answer:
Dynamic programming:
Dynamic programming is an algorithmic design method that can be used when the solution to a problem can be viewed as the result of a sequence of decisions. The dynamic programming approach is similar to divide and conquer. The given problem is divided into smaller and yet smaller possible subproblems.

Dynamic programming is used whenever problems can be divided into similar sub-problems so that their results can be re-used to complete the process. Dynamic programming approaches are used to find the solution in an optimized way. For every inner subproblem, the dynamic algorithm will try to check the results of the previously solved sub-problems. The solutions of overlapped subproblems are combined in order to get a better solution.

Steps to do Dynamic programming:

  1. The given problem will be divided into smaller overlapping sub-problems.
  2. An optimum solution for the given problem can be achieved by using the result of a smaller sub-problem.
  3. Dynamic algorithms use Memoization.

Fibonacci Series – An example:
Fibonacci series generates the subsequent number by adding two previous numbers. Fibonacci series starts from two numbers – Fib 0 & Fib 1. The initial values of fib 0 & fib 1 can be taken as 0 and 1.
Fibonacci series satisfies the following conditions:
Fibn = Fibn-1 + Fibn-2
Hence, a Fibonacci series for the n value 8 can look like this
Fib8 = 0 1 1 2 3 5 8 13

Fibonacci Iterative Algorithm with Dynamic programming approach:
The following example shows a simple Dynamic programming approach for the generation of the Fibonacci series.
Initialize f0 = 0, f1 = 1
step – 1: Print the initial values of Fibonacci f0 and f1
step – 2: Calculate fibanocci fib ← f0 + f1
step – 3: Assign f0 ← f1, f1 ← fib
step – 4: Print the next consecutive value of Fibonacci fib
step – 5: Go to step – 2 and repeat until the specified number of terms generated
For example, if we generate Fibonacci series up to 10 digits, the algorithm will generate the series as shown below:
The Fibonacci series is: 0 1 1 2 3 5 8 1 3 2 1 3 4 5 5

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

12th Computer Science Guide Algorithmic Strategies Additional Questions and Answers

Choose the best answer: (1 Marks)

Question 1.
Which one of the following is not a data structure?
(a) Array
(b) Structures
(c) List, tuples
(d) Database
Answer:
(d) Database

Question 2.
Linear search is also called
a) Quick search
b) Sequential search
c) Binary search
d) Selection search
Answer:
b) Sequential search

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 3.
Which is a wrong fact about the algorithm?
(a) It should be feasible
(b) Easy to implement
(c) It should be independent of any programming languages
(d) It should be generic
Answer:
(c) It should be independent of any programming languages

Question 4.
Which search algorithm can be done as divide and- conquer search algorithm?
a) linear
b) Binary search
c) Sequential
d) Bubble
Answer:
b ) Binary search

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 5.
Which of the following sorting algorithm is too slow and less efficient?
a) Selection
b) Bubble
c) Quick
d) Merge
Answer:
b) Bubble

Question 6.
Which of the following programming is used whenever problems can be divided into similar sub-problems?
a) Object-oriented
b) Dynamic
c) Modular
d) Procedural
Answer:
b) Dynamic

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 7.
Which of the following is the reverse of Big O?
a) Big μμ
b) Big Ω
c) Big symbol
d) Big ΩΩ
Answer:
b) Big Ω

Question 8.
How many different phases are there in the analysis of algorithms and performance evaluations?
(a) 1
(b) 2
(c) 3
(d) Many
Answer:
(b) 2

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 9.
Which of the following is a finite set of instructions to accomplish a particular task?
a) Flowchart
b) Algorithm
c) Functions
d) Abstraction
Answer:
b) Algorithm

Question 10.
The way of defining an algorithm is called
a) Pseudo strategy
b) Programmatic strategy
c) Data structured strategy
d) Algorithmic strategy
Answer:
d) Algorithmic strategy

Question 11.
Time is measured by counting the number of key operations like comparisons in the sorting algorithm. This is called as ……………………………
(a) Space Factor
(b) Key Factor
(c) Priori Factor
(d) Time Factor
Answer:
(d) Time Factor

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 12.
Efficiency of an algorithm decided by
a) Definiteness, portability
b) Time, Space
c) Priori, Postriori
d) Input/output
Answer:
b) Time, Space

Question 13.
Which of the following should be written for the selected programming language with specific syntax?
a) Algorithm
b) Pseudocode
c) Program
d) Process
Answer: c) Program

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 14.
How many components required to find the space required by an algorithm?
a) 4
b) 3
c) 2
d) 6
Answer:
c) 2

Question 15.
Which of the following component is defined as the total space required to store certain data and variables for an algorithm?
a) Time part
b) Variable part
c) Memory part
d) Fixed part
Answer:
d) Fixed part

Question 16.
Which is true related to the efficiency of an algorithm?
(I) Less time, more storage space
(II) More time, very little space
(a) I is correct
(b) II is correct
(c) Both are correct
(d) Both are wrong
Answer:
(c) Both are correct

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 17.
Time and Space complexity could be considered for an
a) Algorithmic strategy
b) Algorithmic analysis
c) Algorithmic efficiency
d) Algorithmic solution
Answer:
c) Algorithmic efficiency

Question 18.
Which one of the following is not an Asymptotic notation?
(a) Big
(b) Big \(\Theta\)
(c) Big Ω
(d) Big ⊗
Answer:
(d) Big ⊗

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 19.
How many asymptotic notations are mostly used to represent time complexity of algorithms?
a) Two
b) Three
c) One
d) Many
Answer:
b) Three

II. Answer the following questions (2 and 3 Marks)

Question 1.
Define fixed part in the space complexity?
Answer:
A fixed part is defined as the total space required to store certain data and variables for an algorithm. For example, simple variables and constants used in an algorithm.

Question 2.
Write a pseudo code for linear search
Answer:

  • Traverse the array using ‘for loop’
  • In every iteration, compare the target search key value with the current value of the list.
  • If the values match, display the current index and value of the array
  • If the values do not match, move on to the next array element
  • If no match is found, display the search element not found.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 3.
Design an algorithm to find the square of the given number and display the result?
Answer:
Problem: Design an algorithm to find the square of the given number and display the result. The algorithm can be written as:

  • Step 1 – start the process
  • Step 2 – get the input x
  • Step 3 – calculate the square by multiplying the input value ie., square ← x* x
  • Step 4 – display the resulting square
  • Step 5 – stop

The algorithm could be designed to get a solution of a given problem. A problem can be solved in many ways. Among many algorithms, the optimistic one can be taken for implementation.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 4.
Write a pseudo code for bubble sort
Answer:

  • Start with the first element i.e., index = 0, compare the current element with the next element of the array.
  • If the current element is greater than the next element of the array, swap them.
  • If the current element is less than the next or right side of the element, move to the next element.
  • Go to Step 1 and repeat until end of the index is reached.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 5.
Write a pseudo code for selection sort.
Answer:

  • Start from the first element i.e., index= 0, we search the smallest element in the array, and replace it with the element in the first position.
  • Now we move on to the second element position, and look for smallest element present in the sub-array, from starting index to till the last index of sub-array.
  • Now replace the second smallest identified in step-2 at the second position in the or original array, or also called first position in the sub-array.

Question 6.
Write a note on Big omega asymptotic notation
Answer:

  • Big Omega is the reverse Big 0, if Big 0 is used to describe the upper bound (worst – case) of a asymptotic function,
  • Big Omega is used to describe the lower bound (best-case).

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 7.
Name the factors where the program execution time depends on?
The program execution time depends on:

  1. Speed of the machine
  2. Compiler and other system Software tools
  3. Operating System
  4. Programming language used
  5. The volume of data required

Question 8.
Write a note on memoization.
Answer:
Memoization or memoisation is an optimization technique used primarily to speed up computer programs by storing the results of expensive function calls and returning the cached result when the same inputs occur again.

Question 9.
Give examples of data structures.
Answer:
Examples for data structures are arrays, structures, list, tuples, dictionary.

Question 10.
Define- Algorithmic Strategy?
Answer:
The way of defining an algorithm is called Algorithmic Strategy.

Question 11.
Define algorithmic solution?
Answer:
An algorithm that yields expected output for a valid input is called an algorithmic solution

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 12.
Define- Algorithm Analysis?
Answer:
An estimation of the time and space complexities of an algorithm for varying input sizes is called Algorithm Analysis.

Question 13.
What are the different phases in the analysis of algorithms and performance?
Answer:
Analysis of algorithms and performance evaluation can be divided into two different phases:
A Priori estimates: This is a theoretical performance analysis of an algorithm. Efficiency of an algorithm is measured by assuming the external factors.
Posteriori testing: This is called performance measurement. In this analysis, actual statistics like running time and required for the algorithm executions are collected.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

Question 14.
Define the Best algorithm?
Answer:
The best algorithm to solve a given problem is one that requires less space in memory and takes less time to execute its instructions to generate output.

Question 15.
Write a note Asymptotic Notations?
Answer:
Asymptotic Notations are languages that uses meaningful statements about time and space complexity.

Samacheer Kalvi 12th Computer Science Guide Chapter 4 Algorithmic Strategies

III. Answer the following questions (5 Marks)

Question 1.
Differentiate Algorithm and program
Answer:

Algorithm

Program

1 An algorithm helps to solve a given problem logically and it can be contrasted with the program Program is an expression of algorithm in a programming language.
2 The algorithm can be categorized based on its implementation methods, design techniques, etc The algorithm can be implemented by a structured or object-oriented programming approach
3 There is no specific rules for algorithm writing but some guidelines should be followed. The program should be written for the selected language with specific syntax
4 The algorithm resembles a pseudo-code that can be implemented in any language Program is more specific to a programming language

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.3

Tamilnadu State Board New Syllabus Samacheer Kalvi 12th Business Maths Guide Pdf Chapter 5 Numerical Methods Ex 5.3 Text Book Back Questions and Answers, Notes.

Tamilnadu Samacheer Kalvi 12th Business Maths Solutions Chapter 5 Numerical Methods Ex 5.3

Choose the most suitable answer from the given four alternatives:

Question 1.
Δ²y0 =
(a) y2 – 2y1 + y0
(b) y2 + 2y1 – y0
(c) y2 + 2y1 + y0
(d) y2 + y1 + 2y0
Solution:
(a) y2 – 2y1 + y0
Hint:
Δ²y0 = (E – 1)²y0
= (E² – 2E + 1) y0
= E²y0 – 2Ey0 + y0
= y2 – 2y1 + y0

Question 2.
Δf(x) =
(a) f (x + h)
(b) f (x) – f (x + h)
(c) f (x + h) – f(x)
(d) f(x) – f (x – h)
Solution:
(c) f (x + h) – f(x)
Hint:
Δf(x) = f (x + h) – f(x)

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.3

Question 3.
E≡
(a) 1 + Δ
(b) 1 – Δ
(c) 1 + ∇
(d) 1 – ∇
Solution:
(a) 1 + Δ

Question 4.
If h = 1, then Δ(x²) =
(a) 2x
(b) 2x – 1
(c) 2x + 1
(d) 1
Solution:
(c) 2x + 1
Hint:
Δ(x²) = (x + h)² – (x)²
= x² + 2xh + h² – x²
Δ(x²) = 2xh + h²
If h = 1 Δ (x²) = 2x + 1

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.3

Question 5.
If c is a constant then Δc =
(a) c
(b) Δ
(c) Δ²
(d) 0
Solution:
(d) 0

Question 6.
If m and n are positive integers then Δm Δn f(x)=
(a) Δm+n f(x)
(b) Δm f(x)
(c) Δn f(x)
(d) Δm-n f(x)
Solution:
(a) Δm+n f(x)

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.3

Question 7.
If ‘n’ is a positive integer Δn-n f(x)]
(a) f(2x)
(b) f(x + h)
(c) f(x)
(d) Δf(x)
Solution:
(c) f(x)
Hint:
Δn-n f(x)] = Δn-n f(x) = Δ0 f(x)
= f(x)

Question 8.
E f(x) =
(a) f(x – h)
(b) f(x)
(c) f(x + h)
(d) f(x + 2h)
Solution:
(c) f (x + h)

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.3

Question 9.
∇≡
(a) 1 + E
(b) 1 – E
(c) 1 – E-1
(d) 1 + E-1
Solution:
(c) 1 – E-1

Question 10.
∇ f(a) =
(a) f(a) + f(a – h)
(b) f(a) – f(a + h)
(c) f(a) – f(a – h)
(d) f(a)
Solution:
(c) f(a) – f(a- h)

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.3

Question 11.
For the given points (x0, y0) and (x1, y1) the Lagrange’s formula is
(a) y(x) = \(\frac { x-x_1 }{x_0-x_1}\) y0 + \(\frac { x-x_0 }{x_1-x_0}\) y1
(b) y(x) = \(\frac { x_1-x}{x_0-x_1}\) y0 + \(\frac { x-x_0 }{x_1-x_0}\) y1
(c) y(x) = \(\frac { x-x_1 }{x_0-x_1}\) y0 + \(\frac { x-x_0 }{x_1-x_0}\) y0
(d) y(x) = \(\frac { x_1-x }{x_0-x_1}\) y0 + \(\frac { x-x_0 }{x_1-x_0}\) y0
Solution:
(a) y(x) = \(\frac { x-x_1 }{x_0-x_1}\) y0 + \(\frac { x-x_0 }{x_1-x_0}\) y1

Question 12.
Lagrange’s interpolation formula can be used for
(a) equal intervals only
(b) unequal intervals only
(c) both equal and unequal intervals
(d) none of these.
Solution:
(c) both equal and unequal intervals.

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.3

Question 13.
If f(x) = x² + 2x + 2 and the interval of differencing is unity then Δf(x)
(a) 2x – 3
(b) 2x + 3
(c) x + 3
(d) x – 3
Solution:
(b) 2x + 3
Hint:
Given:
f(x) = x² + 2x + 2
Δf(x) = f (x + h) – f (x)
since h = 1
Δf(x) = f (x – 1) – f (x)
= [(x + 1)² + 2(x + 1) + 2] – [x² + 2x + 2]
= [x² + 2x + 1 + 2x + 2 + 2] – [x² + 2x + 2]
= x² + 4x + 5 – x² – 2x – 2
= 2x + 3

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.3

Question 14.
For the given data find the value of Δ³y0 is
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.3 1
(a) 1
(b) 0
(c) 2
(d) -1
Solution:
(b) 0
Hint:
From this data
y0 = 12; y1 = 13; y2 = 15; y3 = 18
Δ³y0 = (E – 1)³ y0
= (E³ – 3E² + 3E – 1) y0
= E³y0 – 3E²y0 + 3Ey0 – y0
= y3 – 3y2 + 3y1 – y0
= 18 – 3 (15) + 3 (13) – 12
= 18 – 45 + 39 – 12
= 57 – 57 = 0

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.3

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2

Tamilnadu State Board New Syllabus Samacheer Kalvi 12th Business Maths Guide Pdf Chapter 5 Numerical Methods Ex 5.2 Text Book Back Questions and Answers, Notes.

Tamilnadu Samacheer Kalvi 12th Business Maths Solutions Chapter 5 Numerical Methods Ex 5.2

Question 1.
Using graphic method, find the value of y when x = 48 from the following data:
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 1
Solution:
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 2
The value of y when x = 48 is 6.8

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2

Question 2.
The following data relates to indirect labour expenses and the level of output
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 3
Estimate the expenses at a level of output of 350 units, by using graphic method.
Solution:
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 4

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2

Question 3.
Using Newton’s forward interpolation formula find the cubic polynomial.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 5
Solution:
Since we use the Newton’s forward interpolation formula.
y(x= x0+nh) = y0 + \(\frac { n }{1!}\) Δy0 + \(\frac { n(n-1) }{2!}\) Δ²y0 + \(\frac { n(n-1)(n-2) }{3!}\) Δ³y0 + ………
To find y at x
∴ x0 + nh = x
0 + n(1) = x
∴ n = x
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 6
= 1 + x + (x² – x) (-1) + 2x (x² – 3x + 2)
y = 1 + x – x² + x + 2x³ – 6x² + 4x
y = 2x³ – 7x² + 6x + 1
∴ f(x) = 2x³ – 7x² + 6x + 1

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2

Question 4.
The population of a city in a censes taken once in 10 years is given below. Estimate the population in the year 1955.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 7
Solution:
Let the year be x and population be y. To find the population for the year 1955.
(ie) The value of y at x = 1955
Since the value of y is required near the beginning of the table, we use the Newton’s forward interpolation formula.
y(x= x0+nh) = y0 + \(\frac { n }{1!}\) Δy0 + \(\frac { n(n-1) }{2!}\) Δ²y0 + \(\frac { n(n-1)(n-2) }{3!}\) Δ³y0 + ………
To find y at x = 1955
∴ x0 + nh = 1955; x0 = 1951, h = 10
⇒ 1951 + n(10) = 1955
10n = 1955 – 1951 ⇒ 10n = 4
n = \(\frac { 4 }{10}\) = 0.4
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 8
y = 35 + 2.8 – 1.08 + 0.064
= 37.864 – 1.08
y = 36.784
∴ Population in the year 1955 is 36.784 (lakhs)

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2

Question 5.
In an examination the number of candidates who secured marks between certain interval were as follows:
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 9
Estimate the number of candidates whose marks are lessthan 70.
Solution:
Since the required mark is at the end of the table, we apply Backward interpolation formula. Let the marks be x and No. of candidates be y.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 10
To find y at x = 70
x = x0 + nh ⇒ 70 = 100 + n(20)
70 – 100 = 20n
20n = -30 ⇒ n = \(\frac { -30 }{20}\)
n = -1.5
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 11
= 235 – 25.5 – 12.375 – 1.125
= 235 – 39
= 196
∴ 196 candidates secured less than 70 marks

Question 6.
Find the value of f(x) when x = 32 from the following table
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 12
Solution:
Since the value of f(x) is required near the beginning of the table, we use the Newton’s forward interpolation formula.
y(x= x0+nh) = y0 + \(\frac { n }{1!}\) Δy0 + \(\frac { n(n-1) }{2!}\) Δ²y0 + \(\frac { n(n-1)(n-2) }{3!}\) Δ³y0 + ………
To find y at x = 32
∴ x0 + nh = 32;
30 + n(5) = 32
5n = 32 – 30 ⇒ 5n = 2
n = \(\frac { 2 }{5}\)
∴ n = 0.4
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 13
= 15.9 – 0.4 – 0.024 – 0.0128 – 0.00832
15.9 – 0.44512 = 15.45488
= 15.45
∴ when x = 32, f(x) = 15.45

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2

Question 7.
The following data gives the melting point of a alloy of lead and zinc where ‘t’ is the temperature in degree c and p is the percentage of lead in the alloy
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 14
Find the melting point of the alloy containing 84 percent lead.
Solution:
Since the required value is at the end of the table, apply backward interpolation formula. To find T at p = 84
T(p= p0+nh) = Tn + \(\frac { n }{1!}\) ∇Tn + \(\frac { n(n+1) }{2!}\) ∇²T0 + \(\frac { n(n+1)(n+2) }{3!}\) Δ³T0 + ………
To find T at P = 84
Pn + nh = 84
90 + n(10) = 84
10n = 84 – 90
10n = -6 ⇒ n = \(\frac { -6 }{10}\)
n = -0.6
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 15
= 304 – 16.8 – 0.24 – 0.091392
= 304 – 17.131392
= 286.86
Hence the melting point of the alloy is 286.86° c.

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2

Question 8.
Find f(2.8) from the following
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 16
Solution:
Since the required value is at the end of the table, apply backward interpolation formula.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 17
To find y at x = 2.8
∴ x0 + nh = 2.8
∴ 3 + n(1) = 2.8
n = 2.8 – 3
n = -0.2
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 18
= 34 – 4.6 – 1.12 – 0.288
= 34 – 6.008
= 27.992
∴ f(2.8) = 27.992

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2

Question 9.
Using interpolation estimate the output of a factory in 1986 from the following data
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 19
Solution:
Here the intervals are unequal. By Lagrange’s in-terpolation formula we have,
x0 = 1974, x1 = 1978, x2 = 1982, x3 = 1990
y0 = 25, y1 = 60, y2 = 80, y3 = 170, and x = 1986.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 20
∴ output in 1986 is 108.75 (thousand tones)

Question 10.
Use lagrange’s formula and estimate from the following data the number of workers getting income not exceeding Rs. 26 per month.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 21
Solution:
Here the intervals are unequal. By Lagrange’s In-terpolation formula we have,
x0 = 15, x1 = 25, x2 = 30, x3 = 35
y0 = 36, y1 = 40, y2 = 45, y3 = 48 and x = 26.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 22
∴ Required No.of workers = 42 Persons (approximately)

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2

Question 11.
Using interpolation estimate the business done in 1985 from the following data
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 23
Solution:
Here the intervals are unequal. By Lagrange’s formula we have,
x0 = 1982, x1 = 1983, x2 = 1984, x3 = 1986
y0 = 150, y1 = 235, y2 = 365, y3 = 525 and x = 1985.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 24
∴ Business done in the year 1985 is 481.25 lakhs.

Question 12.
Using interpolation, find the value of f(x) when x = 15
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 25
Solution:
Here the intervals are unequal, By Lagrange’s in-terpolation formula we have,
x0 = 3, x1 = 7, x2 = 11, x3 = 19
y0 = 42, y1 = 43, y2 = 47, y3 = 60 and x = 15.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2 26

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.2

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.1

Tamilnadu State Board New Syllabus Samacheer Kalvi 12th Business Maths Guide Pdf Chapter 5 Numerical Methods Ex 5.1 Text Book Back Questions and Answers, Notes.

Tamilnadu Samacheer Kalvi 12th Business Maths Solutions Chapter 5 Numerical Methods Ex 5.1

Question 1.
Evaluate Δ (log ax).
Solution:
Δ log (ax) = log (ax + h) – log ax
= log [ \(\frac { ax+h }{ax}\) ] = log[\(\frac { ax }{ax}\) + \(\frac { h }{ax}\)]
= log [1 + \(\frac { h }{ax}\)]

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.1

Question 2.
If y = x³ – x² + x -1 calculate the values of y for x= 0, 1, 2, 3, 4, 5 and form the forward differences table.
Solution:
Given y = x³ – x² + x – 1
when x = 0 y = -1
when x = 1
y = 1 – 1 + 1 – 1 = 0
when x = 2
y = 8 – 4 + 2 – 1 = 5
for x = 0, 1, 2, 3, 4, 5
when x = 3
y = 27 – 9 + 3 – 1 = 20
when x = 4
y = 64 – 16 + 4 – 1 = 51
when x = 5
y = 125 – 25 + 5 – 1 = 104
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.1 1

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.1

Question 3.
If h = 1 then prove that (E-1 Δ)x³ = 3x² – 3x + 1
Solution:
h = 1 To prove (E-1 ∆) x3 = 3×2 – 3x + 1
L.H.S = (E-1 ∆) x3 = E-1 (∆x3)
= E-1[(x + h)3 – x3]
= E-1( x + h)3 – E-1(x3)
= (x – h + h)3 – (x – h)3
= x3 – (x – h)3
But given h = 1
So(E-1 ∆) x3 = x3 – (x – 1)3
= x3 – [x3 – 3x2 + 3x – 1]
= 3x2 – 3x + 1
= RHS

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.1

Question 4.
If f(x) = x² + 3x than show that Δf(x) = 2x + 4
Solution:
Given f(x) = x³ + 3x; h = 1
Δf(x) = f (x + h) – f(x)
= (x + 1)² + 3 (x + 1) – (x² + 3x)
= x² + 2x + 1 + 3x + 3 – x² + 3x
= 2x + 4
∴ Δf(x) = 2x + 4

Question 5.
Evaluate Δ [ \(\frac { 1 }{(x+1)+(x+2)}\) ] by taking ‘1’ as the interval of differencing
Solution:
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.1 2

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.1

Question 6.
Find the missing entry in the following table
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.1 3
Solution:
Since only four values of f(x) are given the polynomial which fits the data is of degree three. Hence fourth differences are zeros.
(ie) Δ4 y0 = 0
(E – 1)4 y0 = 0
(E4 – 4E³ + 6E² – 4E + 1) y0 = 0
E4y0 – 4E³ y0 + 6E²y0 – 4E y0 + 1y0 = 0
y4 – 4y3 + 6y2 – 4y1+ y0 = o
81 – 4y3 + 6(9) – 4(3) + 1 = 0
81 – 4y3 + 54 – 12 + 1 = 0
136 – 12 – 4y3 = 0
4y3 = 124
y3 = \(\frac { 124 }{4}\)
∴ y3 = 31

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.1

Question 7.
Following are the population of a district
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.1 4
Find the population of the year 1911
Solution:
Since only five values of fix) are given, the polynomial which fits the data is of degree four. Hence fifth differences are zeros.
(ie) Δ5 y0 = 0
(E – 1)5 y0 = 0
(E5 – 5E4 + 10E³ – 10E² + 5E – 1) y0 = 0
E5y0 – 5E4y0 + 10E³y0 – 10E²y0 + 5E y0 – y0 = 0
y5 – 5y4 + 10y3 – 10y2 + 5y1 – y0 = 0
501 – 5 (467) + 10(y3) -10 (421) + 5 (391) – 363 = 0
2456 – 6908 + 10y3 = 0
-4452 + 10y3 = 0 ⇒ 10y3 = 4452
y = \(\frac { 4452 }{10}\) = 445.2
The population of the year 1911 is 445.2 thousands

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.1

Question 8.
Find the missing entries from the following.
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.1 5
Solution:
Since four values of f(x) are given we assume the polynomial of degree three. Hence fourth order differences are zeros.
(ie) Δ4y0 = 0 (ie) (E – 1)4 yk = 0
(E4 – 4E³ + 6E² – 4E + 1) yk = 0 ……… (1)
Put k = 0 in (1)
(E4 – 4E³ + 6E² – 4E + 1) y0 = 0
E4y0 – 4E³y0 + 6E³y0 – 4Ey0 + y0 = 0
y4 – 4y3 + 6y2 – 4y1 + y0 = 0
y4 – 4 (15) + 6(8) – 4y1 + 0 = 0
y4 – 4y1 = 12 …….. (2)
Put k = 1 in eqn (1)
(E4 – 4E³ + 6E² – 4E + 1) y1 = 0
y5 – 4y4 + 6y3 – 4y2 + y1 = 0
35 – 4 (y4) + 6(15) – 4(8) + y1 = 0
35 – 4y4 + 90 – 32 + y1 = 0
-4y4 + y1 + 125 – 32 = 0
-4y4 + y1 = -93 ………. (3)
Solving eqn (2) & (3)
Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.1 6
Substitute y = 3 in eqn (2)
y4 – 4(3) = 12
y4 – 12 = 12
y4 = 12 + 12
∴ y4 = 24
The required two missing entries are 3 and 24.

Samacheer Kalvi 12th Business Maths Guide Chapter 5 Numerical Methods Ex 5.1