##### Results
Search Results
Post Author Forum Replies Posted [asc]

 It is working good to me, mylist = [5, 12, 27, 3, 12, 5, 9, 5, 11] print(mylist.count(5)) print(mylist.count(3)) print(mylist) k=mylist.count(12) print(k)Output:C:\Users\sandeep\Downloads>py tes...
sandeep_ganga General Coding Help 7 1,074 Mar-16-2021, 10:45 AM
Post: RE: Simple Palindrome

 reverse string works good to reduce iterations, def is_palindrome(i): if len(i) <= 1 or i.lower() == i[::-1].lower(): return True else: return False print(is_palindrome(...
sandeep_ganga General Coding Help 4 678 Nov-25-2020, 02:21 PM

 "for" will iterate over the given, thus try use "if" to direct compare and see if that helps reservation_name = input(f"\nGood afternoon, Anthony's dinner reservations. \n May I have your full name p...
sandeep_ganga General Coding Help 4 570 Nov-20-2020, 03:26 PM

 I doubt S_ID column had whitespaces, import pandas as pd df=pd.read_excel(open('b111.xlsx', 'rb'),sheet_name='Sheet1') print(df) #adding len coluumn df['id_char_length']=df['id'].astype(str).map(l...
sandeep_ganga Data Science 4 840 Nov-20-2020, 02:57 PM

 See below, i used to typecast to str only at print, rest comparisons in int. print('hello world!') print('What is your name?') name=input() print('That is a nice name, '+name) print('How old are you,...
sandeep_ganga General Coding Help 4 748 Nov-20-2020, 09:56 AM

 I tried something as below, see if it helps file = open('h.txt', 'r') for each in file: print (each) k=each.split() ###print(k) j=[] for i in k: ### print(i[:2]) j.append(i[:...
sandeep_ganga General Coding Help 9 1,103 Oct-03-2020, 06:23 AM

 Try this to see if helps, recs = {1: ['Susan Smith', '[email protected]'], 2: ['Cole Brown', '[email protected]'], 3: ['Sue John', '[email protected]']} print(recs) temp=[] for key,val in recs.items(): f...
sandeep_ganga Homework 11 1,757 Feb-04-2020, 07:26 AM
Post: RE: Tip Calculator

 try this to see if helps, first_name = input ("What is the servers name? ") price_meal = float(input("What is the check amount? ")) tip_p = float(input("Tip Percent? ")) tip=price_meal*(tip_p/100) pr...
sandeep_ganga Homework 4 903 Feb-03-2020, 07:51 AM

 Try this, converting object to datetime64 type display['DATE']= pd.to_datetime(display['DATE'],format='%Y-%m-%d') display['DATE']= pd.to_datetime(display['DATE']).dt.strftime('%d-%m-%Y') import pan...
sandeep_ganga Data Science 14 3,007 Jan-27-2020, 12:12 PM

 Try this to see if helps, both programs wont exit until we input match word defined in if block, and both act independent. #starter.py import subprocess import os from subprocess import Popen, CREAT...
sandeep_ganga General Coding Help 11 1,571 Jan-23-2020, 12:36 PM

 Try this to see if that helps, import pandas as pd df=pd.read_csv("ab.csv",header=0, names=['roadno']) print(df) data=[] for i in df['roadno']: if i[:1].lower()=="h" or i[:1].lower()=="m": #if i...
sandeep_ganga General Coding Help 2 930 Jan-23-2020, 08:35 AM

 try this to see if that helps, my_name = input("What is your name? ") my_secondname = input("What is your second name? ") age = int(input("What is your age? ")) measurement = input("What unit of me...
sandeep_ganga General Coding Help 5 1,165 Jan-22-2020, 05:18 PM

 Hi, I was finally able to manage install and use jupyter notebook. Google helped. python -m pip install jupyterlab python -m pip install jupyter python -m pip install notebook python -m notebook #it...
sandeep_ganga Data Science 14 3,007 Jan-22-2020, 04:47 PM

 I doubt indentation is erroring you, try below to see if that helps score=99 if score == 100: print(f"congrats, you reached {score}\n") else: print("Almost at 100\n")Output:python test1.py Almost ...
sandeep_ganga General Coding Help 3 947 Jan-22-2020, 04:38 PM
Post: RE: Need help solving this

 try using below to see if that helps, from random import choice def choosedishes(days): count=0 while count < days: chosendish=choice(foodwelike) if chosendish not in mymenu: mymenu.appen...
sandeep_ganga General Coding Help 3 901 Jan-21-2020, 11:06 AM

 Try this to see if that helps, list1=['man12','11', '12', '14', '20', '21', '23', '24', 'man', '1', '27', '28', '29.1', '30'] mydefectlist=[] mydefectlist1=[] mydefectlist2=[] for item in list1: t...
sandeep_ganga General Coding Help 4 1,126 Jan-17-2020, 09:11 AM

 Not sure if i missed something, Given a set of N measurements, (r1, r2, . . . , rN ) - reflectance array we will initially assign the odd-numbered measurements to class 1 - find odd numbers, odd me...
sandeep_ganga Homework 11 2,164 Jan-13-2020, 03:43 PM

 It works good for any number of elements we pass, since we have for loop added to run till range of input given "totalsize=np.size(reflectance) for i in range(totalsize):" And the statement, "if (ref...
sandeep_ganga Homework 11 2,164 Jan-13-2020, 10:41 AM

 Can you try below to see if that helps, import numpy as np import math def find_nearest(array, value): array = np.asarray(array) idx = (np.abs(array - value)).argmin() return array[idx...
sandeep_ganga Homework 11 2,164 Jan-13-2020, 05:43 AM

 Try this to see if it helps, items=['paper','scissors','rock']# items list i=True while i==True: #read strings , convert lower p_1=input("\nenter player 1 choice: ").lower() p_2=input("enter playe...
sandeep_ganga Homework 2 2,193 Jan-10-2020, 07:14 AM

### User Panel Messages

##### Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020