No products in the cart.

Ask questions which are clear, concise and easy to understand.

Ask Question
  • 1 answers

🦋Tejasvi Singh🦋 3 years, 3 months ago

File "compiler.py", line 1 import random Fruits=["Apple","Mango","Berry","Grapes","Lemon"] start=random.randrange(2)+1 stop=random.randint(start+1,start+2) for i in range(start,stop): print(Fruits[i],end="&") a)Apple&Mango& b)Mango&Berry& c)Mango& d)Berry&Grapes&Lemon ^ SyntaxError: invalid syntax
  • 1 answers

Sia ? 3 years, 4 months ago

an activity that is natural to or the purpose of a person or thing.

  • 3 answers

❤️Ritesh Gupta? 3 years, 3 months ago

Am back... Follow me on Instagram- riteshgupta16_

Sm . 3 years, 3 months ago

I am heal and hearty ... What about you .. ?? You will sleep now right gonna sleep now .. good night

? Royal Thakur ? 3 years, 3 months ago


Good evening sis ...yes I know ...
... I will report him very soon ...
How are you ..?
  • 2 answers

Tannu Rao 3 years, 4 months ago

Use database_name ;

Tannu Rao 3 years, 4 months ago

Use <database_name>;
  • 1 answers

Preeti Dabral 3 years, 4 months ago

Int function is a very simple function used to convert any number into an integer value. Integer values are any number which is a whole number, but it can be a positive number or negative number.

  • 1 answers

Preeti Dabral 3 years, 4 months ago

Actually you need to create a nested dictionary with name as values and another dict as keys, in pretty way the nested dict may look like:

{

'anmol': {'chemistrymarks': 3, 'physicsmarks': 2, 'mathmarks': 1},

'uppal': {'chemistrymarks': 6, 'physicsmarks': 5, 'mathmarks': 4}

}

So you need to add the following lines to create a nested dictionary.

 

num_students = int(raw_input("Please enter number of students:"))

print "you entered %s students" %num_students

student_info = {}

student_data = ['Math marks : ', 'Physics marks : ', 'Chemistry marks : ']

for i in range(0,num_students):

student_name = raw_input("Name :")

student_info[student_name] = {}

for entry in student_data:

student_info[student_name][entry] = int(raw_input(entry)) #storing the marks entered as integers to perform arithmetic operations later on.

#print student_info

print"Please enter student name ?"

name = raw_input("Student name : ")

if name in student_info.keys():

print "Average student marks : ", str(sum(student_info[name].values())/3.0)

else:

print"please enter valid name"

  • 1 answers

Preeti Dabral 3 years, 4 months ago

schooldict ={}

no_of_class=int(input('Enter the number of classes:'))

for x in range(1,no_of_class+1):

schooldict[x] = input('Enter the teacher names:')

print("Display:")

print(schooldict)
 

classId=int(input('Enter class Id:'))

if classId in schooldict:

print ("teacher name: " + str(schooldict[classId]) + "\n")

  • 1 answers

Preeti Dabral 3 years, 4 months ago

t=tuple( )

n=int(input("enter any no.:"))

for i in range(n):

a=input("enter number:")

t+=(a,)

print(t)

for i in t:

print(i)

print(max(t))

print(min(t))

Explanation: first we have created a tuple by accepting values from the user .and we display it's elements one after the another also it will display the minimum and maximum value

  • 1 answers

Preeti Dabral 3 years, 4 months ago

n = int(input("Enter the number of subjects: "))

l = list()

for i in range(n):

 x = float(input("Enter the marks: "))

 l.append(x)

print(l, "is the given list of marks.")

print()

tot = int(input("Enter the total marks of the test: "))

ntot = n*tot

ftot = sum(l)

print("Total marks: ", ftot)

print("Percentage: ", (ftot/ntot)*100)

  • 1 answers

Preeti Dabral 3 years, 5 months ago

Parameters refers to the list of variables in a method declaration. Arguments are the actual values that are passed in when the method is invoked. When you invoke a method, the arguments used must match the declaration's parameters in type and order.

  • 1 answers

Ritika Agrawal 3 years, 5 months ago

No, in cbse class 12 boards only python of class 12 is included.
  • 1 answers

Preeti Dabral 3 years, 5 months ago

lst=eval(input(“Enter list:”))
length=len(lst)
mean=sum=0
for i in range(0,length):
sum+=lst[i]
mean=sum/length
print(“Given list is:”,lst)
print(“The mean of the given list is:”,mean)

  • 2 answers

Preeti Dabral 3 years, 5 months ago

A Lambda Function in Python programming is an anonymous function or a function having no name. It is a small and restricted function having no more than one line. To do so, you will use the lambda keyword (just as you use def to define normal functions).

Abhishek Kumar 3 years, 5 months ago

, can you give example please
  • 0 answers
  • 3 answers

Ritika Agrawal 3 years, 5 months ago

Just do NCERT it's more than sufficient.

###### ₹₹₹₹₹₹ 3 years, 5 months ago

Class 11 ncert

Black Panther 3 years, 5 months ago

Ncert
  • 3 answers

###### ₹₹₹₹₹₹ 3 years, 5 months ago

Name = xyx print('Name')

❤️Ritesh Gupta? 3 years, 5 months ago

Follow me on Instagram- riteshgupta16_

❤️Ritesh Gupta? 3 years, 5 months ago

Royal bro kaise hoo
  • 1 answers

Rashmi Raj 3 years, 5 months ago

Computer science is the study of computers and computing as well as their theoretical and practical applications. Computer science applies the principles of mathematics, engineering and logic to a plethora of functions including algorithms formulation, software and hardware development, and artificial intelligence.

myCBSEguide App

myCBSEguide

Trusted by 1 Crore+ Students

Test Generator

Test Generator

Create papers online. It's FREE.

CUET Mock Tests

CUET Mock Tests

75,000+ questions to practice only on myCBSEguide app

Download myCBSEguide App