78 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for RJPII

I have been browsing the web for days now trying to find a solution to my problem and have yet to come up with anything so far so I figured I would ask some professionals. Basically I need to read a text file which contains records along the lines of: …

Member Avatar for Syed Umair Mohsin
0
12K
Member Avatar for john10

Hey guys, I would like some help regarding saving or reading to or from a bin file. I've read several online tutorials about file input/output, however it doesn't given specific information when applying it to both an array of structures. My knowledge of pointers is weak, as I constantly need …

Member Avatar for jimmichaels29
0
3K
Member Avatar for scheppy

Hello All. I have a program that automatically restarts itself atfer a certain amount of time. I am doing this to test some things out. The program is wrapped in a jar. I run the jar from terminal with java -jar ProgramName.jar It will run and will output all the …

Member Avatar for scheppy
0
376
Member Avatar for Niloofar24

Hello my friends. Look at this please: >>> from bs4 import BeautifulSoup >>> import urllib2 >>> url = urllib2.urlopen('https://duckduckgo.com/?q=3D&t=canonical&ia=meanings') >>> soup = BeautifulSoup(url) >>> links = soup('a') >>> print links [<a class="header__logo-wrap" href="/?t=canonical" tabindex="-1"><span class="header__logo">DuckDuckGo</span></a>, <a class="search__dropdown" href="javascript:;" id="search_dropdown" tabindex="4"></a>, <a href="https://duckduckgo.com/html/?q=3D">here</a>] >>> I used this `https://duckduckgo.com/?q=3D&t=canonical&ia=meanings` as the url, …

Member Avatar for vegaseat
0
588
Member Avatar for Niloofar24

Hello! How can ask my scipt to print **every word** in a url page that starts with the letter "A" in this case? This is my code: from bs4 import BeautifulSoup import urllib2 url = 'http://www.thefamouspeople.com/singers.php' html = urllib2.urlopen(url).read() soup = BeautifulSoup(html) for word in soup.text: if soup.text.startswith('A'): print soup.text …

Member Avatar for vegaseat
0
486
Member Avatar for SkateX

Greetings, I'm having problems with my output. Essentially I am just trying to print out any Cat who is over 3 years old and has Claws. But my output keeps printing out either nothing at all or the 3rd cat 3 times. I've struggled with this for hours trying to …

Member Avatar for JamesCherrill
0
296
Member Avatar for markdean1989

I wonder why this program does not do any changes to the text file that I am trying to modify. Scenario: My program uses the Fstream header file, I declared infile as IFSTREAM and outfile as OFSTREAM. I simply want to transfer data from infile to outfile. The data is …

Member Avatar for markdean1989
0
516
Member Avatar for acrocephalus

Hello, I have a code which generates QR codes from a csv file: #Importar base de dades pathFile = ('E:\Usuarios\Daniel\Documents\APNAE\QR\Llistat_socis_alta.csv') socisAPNAE = pd.read_csv(pathFile, delimiter = ';', encoding='ISO-8859-1') #generar codi QR for i in range(0,len(socisAPNAE.index)): soci = socisAPNAE.iloc[i,1:6] nom = socisAPNAE.iloc[i,1] nom = nom.encode('latin-1') qr = QRCode(version=20, error_correction=ERROR_CORRECT_L) qr.add_data(soci) qr.make() im …

Member Avatar for acrocephalus
0
344
Member Avatar for Yozuru

Hello good people I am working on a caeser cipher program for class. However, I ran into a problem with my outputs. Up to a certain point for example: two('y', 'z') Would give a '\x92' output instead of a 'x' output. Currently this is my code so far: def chartonum(ch): …

Member Avatar for Yozuru
0
285
Member Avatar for Kniggles

hi I am having trouble on echoing a sum from a table, The mysqul works and give me the wantted result and looks like SELECT sum(brick) FROM `goodship` this is the code i am trying to get to show it on the site, <html> <head> <?php $con=mysqli_connect("hostwiththemost.com","bulderbob","superscreatpassword","shipstable"); if (mysqli_connect_errno()) { …

Member Avatar for kgavhane12
0
226
Member Avatar for Start4me

I’m trying to create a textbox, where the user enters a number, and the output shows a word representing each digit, each word is in an individual label created by the code, regardless of how many digits are entered. So if the user enters 153, the output will be: one …

Member Avatar for Start4me
0
485
Member Avatar for CoilFyzx

Oh boy They ust be tired of me now. My trouble: I have two ArrayLists of custom classes. ``ArrayList<Subject>` **a**` ``ArrayList<Student>` **b**` Within those custom classes are other custom classes which themselves have primitive data types as well as an ArrayList of other custom classes. It's a big circus going …

Member Avatar for JamesCherrill
0
562
Member Avatar for Pickletronic

Hello, I've been trying to create a function to calculate and return the total payment. RadioDay is a radio button with value of 7 while RadioHour is 70. Somehow I am getting InvalidCastException "Conversion from string "" to type 'Integer' is not valid." from the part where I want to …

Member Avatar for Pickletronic
0
333
Member Avatar for Jed_1

I've implimented this snippet of code dijkstra_shortest_paths( g, name2v[tempName1], get(&VertexProperty::predecessor, g), get(&VertexProperty::distance, g), get(&EdgeProperty::weight, g), boost::identity_property_map(), // index-map std::less<double>(), // compare std::plus<double>(), // combine std::numeric_limits<double>::infinity(), // infinity 0.0, // zero do_nothing_dijkstra_visitor(), get(&VertexProperty::color, g)); to use dijkstra's on a map created from a text file, but I have no idea how …

Member Avatar for Jed_1
0
833
Member Avatar for davidjennings

Hi All I am trying to find out the best way to capture the var_dump($contents) on line 29. I am think array? but I don't know how many string elements the array is returning. This is the output via var_dump($contents); array (size=45) 0 => string '.' (length=1) 1 => string …

Member Avatar for davidjennings
0
350
Member Avatar for arkulin

I am trying to create stored procedure which will insert one row in the first table and identity of inserted row in other two tables. For some reason I am receiving error "Procedure or function expects parameter '@id', which was not supplied.". My code is as follows: ALTER PROCEDURE InsertProf …

Member Avatar for arkulin
0
379
Member Avatar for can-mohan

Hi All, I have doubt in my mind regarding declaration of cin and cout object . As per my understanding cin and cout both object are accessible in main then they shouldn't have protected.in below code snippet i have overloaded both input and output operator and while giving new name …

Member Avatar for can-mohan
0
447
Member Avatar for urbanthistleuk

Hello, First of all apologies if this has been posted before, having trouble findin the answer, Let me start by inserting the code I have having the problem with, apologies if this isn't the correct way of doing things but I am still a newbie at php <?php include('config.inc'); mysql_select_db($dbname); …

Member Avatar for urbanthistleuk
0
262
Member Avatar for lupacarjie

Hello! I am creating an assembly program that accepts a single character and displays the alphabet in reverse. The requirements are (1) The input character should be displayed (2) The alphabet should be displayed vertically and (3) Only the letter 'Z' should be accepted as input. I have managed to …

Member Avatar for lupacarjie
0
9K
Member Avatar for DeadH34d

I've been reading through this introductory book on Python, and I've been following along fairly well. Compared to C++, Python seems to make more sense to me. That is, until I reached a section on Logical Operators. I don't completely understand what I just typed in to IDLE, and the …

Member Avatar for Gribouillis
0
406
Member Avatar for abra_ka_dabra

I am using the following code to write to the file out1.txt: try{ FileWriter fostream = new FileWriter("out1.txt"); BufferedWriter out = new BufferedWriter(fostream); out.write("jlsdfjdlsfhsdkjf"); out.close(); }catch (Exception e){ System.err.println("Error: " + e.getMessage()); } Now i want to write to multiple files in the same code (let us say 2 files). …

Member Avatar for JamesCherrill
0
6K
Member Avatar for Nubitol

anyone can help me? i have a task from my teacher. He asked me to make a simple image processing program that can process 2D image with this feature: -the program can make a translation, rotation (an angle of rotation with arbitrary), scaling, and shearing. -the program can make an …

Member Avatar for JamesCherrill
0
329
Member Avatar for robert.speciale

I'm still a bit of a newbie and have what is probably a minor issue, but for some reason I can't wrap my mind around it. I have a program that does a whole bunch of stuff to text from an input file. The input looks like this: MArch 9, …

Member Avatar for deceptikon
0
149
Member Avatar for atikah8890

Hi all. I have two tables (question and answer) with q_id as the link. I would like to output the data that each table holds alternately like this: [Question 1] [Question 1 Choice of Answers] [Question 2] [Question 2 Choice of Answers] ...and so on. I've managed to filter the …

Member Avatar for broj1
0
438
Member Avatar for 123386761

Hello! I'm new here, so correct me if this is the wrong location... but I'm trying to make a program for the Minecraft server I'm on, and it requires that if someone wants to make a map that is used on the server, that there's a .xml file that shows …

Member Avatar for 123386761
0
184
Member Avatar for primzon

Hello guys! Please help me with a little problem. I have one table(Person) where are some values. My current syntax is: SELECT Status, COUNT(Name) AS Number FROM Person WHERE Status = 'Married'; Result: Status_________Number --------------------- Married__________3 But I want to get the result for each status. That would be something …

Member Avatar for JorgeM
0
194
Member Avatar for Secone

I have a template in a 1-file .h file, and I need it to be adjusted and modified to work properly with only a partial amount of the items in it used. The testArray.cpp file I include is how I test if it works properly. As it is now, it …

Member Avatar for Secone
0
183
Member Avatar for Labdabeta

Hi, I am wondering if there is a somewhat simple way to output extended ascii values in c. Basically I am thinking actually about unicode characters, stored in ints. Is there an easy way to do this, or would it require a custom gui console?

Member Avatar for Labdabeta
0
231
Member Avatar for anglwthnati2de

Hi guys. I am having issues with the output of this program. Can somebody tell me what I have to do to make this work correctly? Here is the code I have so far: import java.util.Scanner; //text scanner to parse primitive types and strings using regular expressions. public class Operations …

Member Avatar for anglwthnati2de
-2
272
Member Avatar for ShEeRMiLiTaNt

Hello, I need to write a program to take in a name (max 101 characters) and out store in into an array so that I can output it like a list. These 2 programs are apart of a bigger program that keeps asking if you want to add another name …

Member Avatar for VernonDozier
0
321

The End.