5-25 C++ Comparing Strings From a Text File (Working with external text files)

  Рет қаралды 24,537

Coding Homework

Coding Homework

Күн бұрын

Пікірлер: 25
@KoloStories
@KoloStories 8 жыл бұрын
I believe that I learned more in your video in ten minutes, than nearly an hour in class. Thanks man!
@martinbraescher894
@martinbraescher894 2 жыл бұрын
class is for dumb people
@donovanscott4311
@donovanscott4311 8 жыл бұрын
Dude I just wanted to thank you so much for making these videos!! You have no idea how much they have been helping me get a more intuitive thought on the control structures of basic programming skills. I am a college student, and your videos help me more than the limited time we get in class; not that it is the professors fault or anything, i just know this particular subject takes up alot of time and practice is key, yet, despite your accent you speak great english and your instructions and videos are clear and precise! If I get an A or B in this class this semester I owe most of it too your tutorials and explanations! Thanks again :)!!!
@MrJackblack5
@MrJackblack5 9 жыл бұрын
Yea I'm doing this program in my csc1 class right now and was confused on this part of the program but this helped out alot. Thank you so much!!!
@codingchallenges
@codingchallenges 9 жыл бұрын
+MrJackblack5 You're very welcome
@hasanrants
@hasanrants Жыл бұрын
done! 12:36PM PKT, Saturday 16th December 2023
@DCALVERTMW2
@DCALVERTMW2 9 жыл бұрын
Very good video. I have this assignment right now in my c++ class and was very confused on how to do it. This helped so much, Thanks!
@codingchallenges
@codingchallenges 9 жыл бұрын
DCALVERTMW2 Glad it was halpful
@yogeshwaranyoge7188
@yogeshwaranyoge7188 7 жыл бұрын
hi its nice tutorial, can u do for a problem i have with files, to read a file with name and a random numbers and to sort the names based on the given random numbers of the file
@sumitmohite4908
@sumitmohite4908 4 жыл бұрын
I don't understand while inputfile >> name
@THomasJefferRson
@THomasJefferRson 3 жыл бұрын
How do you add the file to your project?
@froglin
@froglin 7 жыл бұрын
Another question for you is what if you had multiple numbers from a file that you want to store into multiple variables? do you do inputFile >>num>>num2>>num3>>num4>>num5? or do you do something like inputFile= Num1; and go down the list until inputFile = num5;? I have troubles understand input files and how they store numbers
@zaynabboustique1288
@zaynabboustique1288 2 жыл бұрын
what if you wanted to display the whole list of names in alphabetical order?
@Origon09
@Origon09 5 жыл бұрын
I’m not getting any output. I’m not sure if it’s my file. But I’m on Mac using Xcode and it still keeps giving me nothing
@okuratnywidz3196
@okuratnywidz3196 4 жыл бұрын
How to create text im winapi this is the same Code ?
@Soohia67418
@Soohia67418 8 жыл бұрын
Nice bro.! This is really helpful for beginner.
@Deckintheschnoz
@Deckintheschnoz 7 жыл бұрын
I just had a question: When i had a name starting with a capital "Z" then it would be displayed ahead of any letter starting with a small 'a'. For example: if i had the following names: Zelda ash .... then "Zelda" would appear as the first name. I mean, is the program supposed to run that way? Or is there any mistake in the program?
@codingchallenges
@codingchallenges 7 жыл бұрын
This is an old video, and I'd do it differently now. The problem is with the way ASCI characters are "read" by the computer. Capital letters come before lower case, so yes, Zelda would be technically, as far as the computer is concerned, before ash. In fact, even characters such as '\', '[' etc are alphabetically before lowercase letter 'a'. (see www.asciitable.com/) To ignore the case of the letters, it would be best to convert all characters in each word to either lower case or upper case, that way, you would be comparing characters from the same ASCI sequence.
@dmaster20ify
@dmaster20ify 7 жыл бұрын
Nice video. The program worked even though I modified some tiny tiny tiny details: name of file, ifstream object name, and other variable name. Problem is I didn't learn how to read data from a file. And I still don't understand how to compare strings in a file or how your program even works. The whole think is like a magic trick. You only assigned the value of name to everything!??! 1. What is the purpose of int counter? 2. How does string name work? does it assign names in the file to it line by line? 2.A: If so, how does it know to assign names line by line? 3. What is the purpose of each of the string variables declared?
@dmaster20ify
@dmaster20ify 7 жыл бұрын
Ok so I did some research and experiment and finally cracked the mysteries of your program. This reminds me of the identify_prime_number program that the Indian youth from "The Pentamollis Project" channel gave me. It's always the simple codes that knock you out cold.
@codingchallenges
@codingchallenges 7 жыл бұрын
Glad you were able to figure it out! I believe that's the best way to not only learn something, but also to retain that knowledge. On another note, this video is fairly old, and there is now a new C++ version, so some things may be done differently as far as syntax go.
@dmaster20ify
@dmaster20ify 7 жыл бұрын
Right, video is like 3 years old. Also I saw where you made a comment to Samir Khanal, saying that your method is a bit old, and you use a modern method now. Sadly you didn't state the modern method. Does the modern method for making this program involve using Unicode instead of ASCI; or did you use some special C++ function or libraries?
@eve_ai_jiang6979
@eve_ai_jiang6979 6 жыл бұрын
back in my day, a "couter" referred to a vajayjay!
6-1 C++ Calculate Markup Cost With Functions
10:35
Coding Homework
Рет қаралды 10 М.
C++ Tutorial 29 - Reading and Writing to Files - fstream
15:41
programminghelporg
Рет қаралды 798 М.
Хаги Ваги говорит разными голосами
0:22
Фани Хани
Рет қаралды 2,2 МЛН
Война Семей - ВСЕ СЕРИИ, 1 сезон (серии 1-20)
7:40:31
Семейные Сериалы
Рет қаралды 1,6 МЛН
C++ String Comparison (using String.Compare, String Methods, Loops)
13:14
C++ Tutorial for Beginners 42 -Create a Text File and Write in It
10:19
ProgrammingKnowledge
Рет қаралды 192 М.
C++ Tutorial for Beginners 43 - How to Read from a .txt file using C++
14:28
ProgrammingKnowledge
Рет қаралды 324 М.
C++ 7-1 Finding Largest and Smallest Array Values in Array
11:19
Coding Homework
Рет қаралды 68 М.
5-14 C++ Finding Lowest & Highest String Using C++ Loops
16:12
Coding Homework
Рет қаралды 10 М.
C++ Tutorial 18 - Vectors and Vector Functions
16:14
programminghelporg
Рет қаралды 512 М.
7 Outside The Box Puzzles
12:16
MindYourDecisions
Рет қаралды 300 М.