Linux Help
guides forums blogs
Home Desktops Distributions ISO Images Logos Newbies Reviews Software Support & Resources Linuxhelp Wiki

Welcome Guest ( Log In | Register )



Advanced DNS Management
New ZoneEdit. New Managment.

FREE DNS Is Back

Sign Up Now
 
Reply to this topicStart new topic
> How To Calculate Age By Date Of Birth, HELP PLEASE!
Nathan
post Nov 18 2005, 07:58 AM
Post #1


Whats this Lie-nix Thing?
*

Group: Members
Posts: 2
Joined: 17-November 05
Member No.: 5,751



Hi guys, i am really stuck with linux. sad.gif

As part of my assignment, i have to:

- "Ask the user's date of birth and calculate his or her age"

How would i write that in Linux, i am all new to this!


Cheers,
Nathan
Go to the top of the page
 
+Quote Post
michaelk
post Nov 18 2005, 11:31 AM
Post #2


Its GNU/Linuxhelp.net
*******

Group: Support Specialist
Posts: 1,800
Joined: 23-January 03
Member No.: 360



Please do not request others to help you with homework. You will learn more by doing it yourself. I do not mind providing hints but you did not provide enough information. Since we do not know what type of class this is nor what programming language your are learning if any nor the linux commands etc that you have already learned it will be difficult to provide help.
Go to the top of the page
 
+Quote Post
Jim
post Nov 18 2005, 06:34 PM
Post #3


Its GNU/Linuxhelp.net
*******

Group: Support Specialist
Posts: 1,280
Joined: 19-November 03
From: University of Minnesota- TC
Member No.: 1,828



Weak.


--------------------
--Jim Lester
jim@linuxhelp.net

Distro: Gentoo
System: AMD Athlon 3000+ XP 2.166 GHz
NVIDIA nForce2 IGP Chipset
1GB 333 MHz DDR SDRAM
NVIDIA nForce2 Dual Head 64 MB Graphics

Server Distro: CentOS
Go to the top of the page
 
+Quote Post
Nathan
post Nov 19 2005, 09:14 AM
Post #4


Whats this Lie-nix Thing?
*

Group: Members
Posts: 2
Joined: 17-November 05
Member No.: 5,751



Shut up!
Go to the top of the page
 
+Quote Post
Jim
post Nov 19 2005, 04:24 PM
Post #5


Its GNU/Linuxhelp.net
*******

Group: Support Specialist
Posts: 1,280
Joined: 19-November 03
From: University of Minnesota- TC
Member No.: 1,828



Dude, honestly, do your homework yourself. What they hell. When you boss askes you to write a script in a four years are you gonna come here and ask for help? As a CSci student myself I will promise you that you are far better off figuring it out for yourself.

And two, honestly dude, how hard is it to subtract the birthdate from the current date.

And three: If you actually expected us to help you, you would have to give us a little more information, like, of I don't know, what language you needed to do it in.


--------------------
--Jim Lester
jim@linuxhelp.net

Distro: Gentoo
System: AMD Athlon 3000+ XP 2.166 GHz
NVIDIA nForce2 IGP Chipset
1GB 333 MHz DDR SDRAM
NVIDIA nForce2 Dual Head 64 MB Graphics

Server Distro: CentOS
Go to the top of the page
 
+Quote Post
DS2K3
post Nov 19 2005, 06:26 PM
Post #6


Its GNU/Linuxhelp.net
*******

Group: Support Specialist
Posts: 1,284
Joined: 14-November 04
From: Southampton, Hampshire
Member No.: 4,165



Guys! He didn't just type out his assignment, he asked for some pointers! By all means don't help, but there's no need to be rude to another.

I guess you are trying to use bash (the shell) to do it. Goggling "bash date functions" might bring up some info.

QUOTE
And two, honestly dude, how hard is it to subtract the birthdate from the current date.


TBH Jim, I couldn't do that in bash

Deep breath, count to 10...

smile.gif

D


--------------------
Fixed your problem? Let us know!
richard@linuxhelp.net

www.Gathr.co.uk Online Event Management
Go to the top of the page
 
+Quote Post
Jim
post Nov 20 2005, 04:03 AM
Post #7


Its GNU/Linuxhelp.net
*******

Group: Support Specialist
Posts: 1,280
Joined: 19-November 03
From: University of Minnesota- TC
Member No.: 1,828



Dude, I couldn't do it in bash either off the top of my head. But its pretty blatently obvious that thats what you're going to need to do. You're trying to give him credit for not just typing out his assignment, I wouldn't give him that.

If he had honestly thought about it, and askes "Hey, how do I get the current date in bash?" or "hey, I am having trouble putting the user input into the same format as the date output" I might be a little more willing to help.

Long story short, I am done doing people's homework for them, I know I have answered obviuos homework questions in the past, but no more. You have a complex, specific question that came up durring your homework, fine, but questions like this will not get answers from me.


--------------------
--Jim Lester
jim@linuxhelp.net

Distro: Gentoo
System: AMD Athlon 3000+ XP 2.166 GHz
NVIDIA nForce2 IGP Chipset
1GB 333 MHz DDR SDRAM
NVIDIA nForce2 Dual Head 64 MB Graphics

Server Distro: CentOS
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 13th December 2017 - 05:44 PM