15,886,083 members
Sign in
Sign in
Email
Password
Forgot your password?
Sign in with
home
articles
Browse Topics
>
Latest Articles
Top Articles
Posting/Update Guidelines
Article Help Forum
Submit an article or tip
Import GitHub Project
Import your Blog
quick answers
Q&A
Ask a Question
View Unanswered Questions
View All Questions
View C# questions
View C++ questions
View Javascript questions
View Visual Basic questions
View Python questions
discussions
forums
CodeProject.AI Server
All Message Boards...
Application Lifecycle
>
Running a Business
Sales / Marketing
Collaboration / Beta Testing
Work Issues
Design and Architecture
Artificial Intelligence
ASP.NET
JavaScript
Internet of Things
C / C++ / MFC
>
ATL / WTL / STL
Managed C++/CLI
C#
Free Tools
Objective-C and Swift
Database
Hardware & Devices
>
System Admin
Hosting and Servers
Java
Linux Programming
Python
.NET (Core and Framework)
Android
iOS
Mobile
WPF
Visual Basic
Web Development
Site Bugs / Suggestions
Spam and Abuse Watch
features
features
Competitions
News
The Insider Newsletter
The Daily Build Newsletter
Newsletter archive
Surveys
CodeProject Stuff
community
lounge
Who's Who
Most Valuable Professionals
The Lounge
The CodeProject Blog
Where I Am: Member Photos
The Insider News
The Weird & The Wonderful
help
?
What is 'CodeProject'?
General FAQ
Ask a Question
Bugs and Suggestions
Article Help Forum
About Us
Search within:
Articles
Quick Answers
Messages
Comments by Sharyar Javaid (Top 19 by date)
Sharyar Javaid
2-Aug-23 12:30pm
View
Thank you so much! One more question : If i do: String greet = new String("hello") , I know the string "hello" will be allocated to the HEAP but at the same time this "hello" will also be created in String Constant Pool? so in the next line if I do: String greet2 = "hello" , greet2 will point to the already existing "hello" by greet in the String Constant Pool or it never existed there because of new keyword of greet?
Sharyar Javaid
6-Nov-22 15:36pm
View
Got it. but one thing, you saying like I Can't do anything with loops and termination conditions is quite wrong and judgemental. if you'd like to assume that by just one single problem that does not raise questions on that book.. its rather your own assumption. what I meant to say which I couldnt properly emphasize to you was your calloc function. is what I havent seen yet in that book. Also I was confused behind the logic of this if ((ch != '\r')
Sharyar Javaid
6-Nov-22 15:30pm
View
still thanks for the solution
Sharyar Javaid
6-Nov-22 15:27pm
View
Deleted
Got it. but one thing, you saying like I Can't do anything with loops and termination conditions is quite wrong and judgemental. if you'd like to assume that by just one single problem that does not raise questions on that book.. its rather your own assumption. what I meant to say which I couldnt properly emphasize to you was your calloc function. is what I havent seen yet in that book. Also I was confused behind the logic of this if ((ch != '\r')
Sharyar Javaid
6-Nov-22 14:44pm
View
also if you have time can you please explain what are you doing in the separate function with the conditions and loops. I have studied functions and recursions for basic maths like finding factorial, etc but this function's logic is hard to grasp for me
Sharyar Javaid
6-Nov-22 14:30pm
View
thanks. can you list resources where you've learnt all this? I am currently only learning from "absolute beginner's guide to C by Greg Perry". I have 2/3rd of the book finished but these technical problems havent been shared in detailed.
Sharyar Javaid
5-Nov-22 6:31am
View
it works.. but can you please explain what have you done in the while loop? also what is unsigned long is doing? thanks
Sharyar Javaid
4-Nov-22 3:03am
View
thanks for the answer! but scanf doesn't input spaces. how to tackle that?
Sharyar Javaid
4-Nov-22 2:58am
View
There is only 1 string input in the code that's why I said what I said. dont take it personally. it is clearly evident in the code my friend
Sharyar Javaid
3-Nov-22 7:04am
View
well.. its clearly evident in the code. its part of a bigger code but it doesnt work here so no point going on.. I input medicines category but doesnt work.
Sharyar Javaid
21-Sep-22 17:33pm
View
thanks.Now it does the calculations(for total) as expected but the digit value C is giving me is not what I input. the total is correct though!
Sharyar Javaid
21-Sep-22 15:41pm
View
I only posted it once though! Now what can I do? I dont have the option to delete the other one because its not visible to me
Sharyar Javaid
21-Sep-22 15:18pm
View
what do you mean by that?
Sharyar Javaid
6-Sep-22 11:16am
View
Hey man, thanks for the solution. but the 2nd for loop still is not working. I did everything as you mentioned. what could be the reason?
Sharyar Javaid
26-Aug-22 9:59am
View
thanks! I changed the 'y' to capital 'Y' and it works now also yes if I get rid of the if statement, it works then too! but your 3rd point I could not understand as I'm still halfway throught the book "absolute beginner's guide to C by greg perry" and not yet gone through the buffer
Sharyar Javaid
26-Aug-22 9:40am
View
i mean its not looping! it works one time and then terminates
Sharyar Javaid
24-Jun-22 2:15am
View
THANKS man. but its still working brother beforehand. It doesnt give error but says infinity when divide by 0. which is right i guess.
Sharyar Javaid
23-Jun-22 5:00am
View
Its working now! Can you please explain what you did there? especially what this line Console.WriteLine("Result is : {0}", result); is doing which my code without it couldn't do?Also I already defined a variable double for result in the 2nd method, why did you define it again in the main method since this line takes input from the 2nd method. doesn't it? thanks so much!
Sharyar Javaid
23-Jun-22 4:25am
View
Thanks Tony, but I already tried that. If I set double result = 0; . Yes It runs then but it still does not show the calculations . Only lets the user input 2 numbers and then exits. it doesnt even show 0 as result of calculation.
Show More