Fred Masen

Ranch Hand
+ Follow
since Feb 23, 2019
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Fred Masen

I read in numerous programming blogs that recently a lot of entry level programmers have been fired and their work has been done by ChapGPT. Do you see ChatGPT  as a  threat in the future for experienced programmers as well? as AI will continue to evolve . Thanks for your time.
1 year ago
Sorry I had issues with the server. I get too passionate about programming that's why it gives me issues. But I will try to follow your advice and will return to Java which is the language I feel more comfortable with .  Thanks for your reply!
2 years ago
Well without any reply from you guys , I am going to try again Java I guess.
2 years ago
Hi guys . it has been several months since I visited this forum. As usual the last time I tried learning Java I quite. It is always a question of getting really nervous and not be able to sleep when getting an issue in my programs. I am old and Alzheimer runs in my family so I would like to keep my brain sharp as possible. I played rarely chess now because the stress involved in a game also prevents me to sleep well too. I tried several languages already like C++(basics) Java (went through OOP and graphics design) a tiny Golang and finally python where I got my hairs out of my head because of the white spaces issues and would give me error for (a conditional while loop not well attached to the code). Now the for the past 6 years I have been coming in asking similar question then quit then coming back like today. Now I noticed that each time I make a new try after 6 months or a year I feel that is more difficult for me to learn as I age. So from your experience what would be the best language that will allow me to stick ( Java or Python) with it for a long time without constantly quitting ? What I realize is that programming improve creativity and logic which is what I want and seek for but on the same time too much stress and insomnia can leads to brain shrinking and dementia which is what I am trying to stay away from by learning programming. Anyways What are your thoughts about my question? I know that probably for a few of you I get annoying as I tend to post the same question but for me it will encourage to try again if you feel guys that I should go for it?    By the way happy New Year to all of you.  
2 years ago
Thanks Matthew for your explanations , I appreciate.  Concerning your comment :" but I also have wasted years of time I could had used way more productive or creative or different." Most of us have similar feelings and you are not alone
2 years ago
I wonder if it is normal when you can't figure out an error like the one I just exposed and keep thinking about it ? I mean I tried all morning long. Then I went to walk in the countryside with friends but my brain was keep thinking about it , trying to find a fix , I was unable to enjoy the countryside surrounding me  , unable to pay full attention to the conversation etc.. Is it something that you guys real programmers experienced as well ? Or is it something that will disappear as I will learn and become more knowledgeable  in  Java ?.  I often program during night time around 9PM and if I have a bug , my sleep will be disturbed and light as my brain keeps looking for it and this during sleep time and when I wake up .
Thanks.
2 years ago
Thanks Carey! I have searched for hours on my JOptionPane.showMessageDialog(null,ft.cutCheck(ft.findPaymentAmount()) ); trying to format it etc.. without luck of course. I did try to changed the cutCheck to String but after that I was lost. Well it looks like that I have a lot to learn and a long road ahead of me.. Thanks a lot Carey!
2 years ago
I knew that was the problem because of the compilation error but I have no idea how to change a void method into a toString method.
Especially if it has some strings and a double in it.
2 years ago
I have the super Class which is : Exployee , I have public class FullTimeEmployee extends Employee and finally I have my main program : public class DoPayroll1 . However I have an error when I tried :
JOptionPane.showMessageDialog(null,ft.cutCheck(ft.findPaymentAmount()) ); the error :

Exception in thread "main" java.lang.Error: Unresolved compilation problem:
The method showMessageDialog(Component, Object) in the type JOptionPane is not applicable for the arguments (null, void)

However if I type : ft.cutCheck(ft.findPaymentAmount());  Everything works fine and the results are correct. How can I show the same results(ft.cutCheck(ft.findPaymentAmount())) using JOptionPane.showMessageDialog. I tried everything and every fixes without success. Thanks for your time .

2 years ago
Here Eclipse with Visual Studio Code(With Java extension pack) works fine for me. I would advice to Mark to get a simple Java book or looking over Youtube :" Java Full Course(free)". That way you get familiar on how to use the Eclipse editor as well as writing some basic Java programs up to some more complicated programs using GUI etc.. I tried once Netbeans a long time ago  it was a  piece of crap, I tried using it in 1998 it was slow as crazy with my Window98 and now it has not really improved in my opinion. When you are writing a java program you need to start with : Project name . Then add a class to it(from the src folder) , that's where you write your code don't forget to check public static void main , if it your main program. then click finish. But all these details are explained in the youtube :Java Full Course(free) It is an 11 hours video so get ready to learn Happy learning.
PS: By the way you should try to use Linux-mint it is an easy to use nix distro and will make your life easier to code and it is super fast comparing to this Windows mammoth OS nonsense.  And come back to the forum of you have any other issues.
Ps1: All your folders and files are located in :eclipse-workspace if you are using Eclipse. but when your Eclipse is opened it's in your src folder.
2 years ago
Yep
String j = ";  has a length 0
String j = null; is NULL

I usually initialized myself that way I avoid all the crappy NullPointerException errors
but if I let Eclipse fix it it will initialized as NULL then if you try to use and work with the String like equals etc.. it will throw  a NullPointerException error because I believe it has not yet been allocated space in memory.
But if I don't to manipulate the String and just want to use it that way :
String name = null;
Scanner keyboard = new Scanner(System.in);
System.out.println(" What is your name ? ");
name = keyboard.nextLine();
Then NULL is perfectly fine to use it.

2 years ago
From my experience of you don't initialize the string and later on you want to use it , the compiler(with Eclipse) show an error and ask you to initialized it and will offer you a fix and your string will becomes : String j = null;
or you can do it yourself like this String  j= "";
2 years ago