Posts

Showing posts from August, 2021

Comparison List ,Tuple ,Set , Dictionaries

Image
  Python provides several built-in data structures, each with its own characteristics and use cases. Here's a comparison of lists, tuples, sets, and dictionaries in terms of their properties and common use cases: Lists: Mutable: Lists are mutable, meaning you can modify their elements after creation. Syntax: Defined using square brackets [] . Ordered: Elements are stored in a specific order and can be accessed using indices. Use Cases: Suitable for situations where you need a collection of items that may change, such as a list of tasks, items in a shopping cart, etc. my_list = [1, 2, 3, 'apple', 'orange'] Tuples: Immutable: Tuples are immutable, meaning their elements cannot be modified after creation. Syntax: Defined using parentheses () . Ordered: Similar to lists, elements are ordered and can be accessed using indices. Use Cases: Suitable for situations where you want to create a collection of values that should not be changed, such as coordinates or dim...

Python For Machine Learning - CST 283 - KTU Minor Sample Question Paper and Answer Key Dec 2021

  APJ ABDUL KALAM TECHNOLOGICAL UNIVERSITY THIRD SEMESTER B.TECH DEGREE EXAMINATION, DECEMBER 2020 Course Code: CST283 Course Name: Python for Machine Learning Max. Marks: 100   Duration: 3 Hours   Duration: 3 Hours   Answer all questions. Each question carries 3 marks Marks 1 Describe any three formats used with print statement 3 2 Explain with example the usage of any three methods from math module. 3 3 Write a Python program to find the sum of even digits in a number 3 4 Illustrate the use of functions with an example 3 5 Write a Python program to find the frequency of each word in a string using dictionary. 3 6 Distinguish between List and Tupl...