how long would it take to write a MB of code
-
Did you exclude resources like bitmaps, icons, and such? How about static data files? Help and other documentation? If you exclude that, my team's current product occupies about 100MB in source code. If you add that data in, it's almost 6GB, most of which is static data.
Software Zen:
delete this;
No static data, but there are icons, resource files, which are still hand crafted, so it's OK to include them. So yeah, 10 GB of code. It is huge.
-
C++ say. I was just looking at the product I am working on and in total it has almost 1.2 GB of data in the project directories (after cleaning) HOw long would it take one programmer to write that much code?
Along with the images and static stuff, is auto complete and higher level language compiling. Stub classes might be as quick as 2 or 3 key presses making 20+ characters. then add in simply press // + tab to generate another 20+ characters of method documentation stub. Use entity framework, and simply generate mvc web page with read/write adds some 300+ characters. But in contrast, if write in TypeScript and Less, might take longer to hit 1mb compared to writing it out in pure JS. even jquery shortens number of characters needed to accomplish the same thing in pure js.
-
Along with the images and static stuff, is auto complete and higher level language compiling. Stub classes might be as quick as 2 or 3 key presses making 20+ characters. then add in simply press // + tab to generate another 20+ characters of method documentation stub. Use entity framework, and simply generate mvc web page with read/write adds some 300+ characters. But in contrast, if write in TypeScript and Less, might take longer to hit 1mb compared to writing it out in pure JS. even jquery shortens number of characters needed to accomplish the same thing in pure js.
Most of this is straight off svn, so no autocomplete databases yet built. The two I have worked on I cleaned and deleted these databases so this really is the code size. Seriously, it is immense.
-
C++ say. I was just looking at the product I am working on and in total it has almost 1.2 GB of data in the project directories (after cleaning) HOw long would it take one programmer to write that much code?
Munchies_Matt wrote:
HOw long would it take one programmer to write that much code?
It depends on third party products and how many spaguetti code from the internet he had copied
M.D.V. ;) If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about? Help me to understand what I'm saying, and I'll explain it better to you Rating helpful answers is nice, but saying thanks can be even nicer.
-
There are 86,400 seconds in one day. So, if the dev typed one character (of code) / sec then it would take more than 13,888 days to type 1.2 GB of code. 13,888 days = 38 years. Of course, that is typing constantly for 38 years straight without doing anything else. :rolleyes: EDIT Oh, you said 1 MB. Well... About 11.5 days of solid typing. :laugh:
Pshaw. One character per second? That's really slow for typing speed.
**<BullshitWarning>**
Let's use my 80 year-old mother as a test subject here. She's a classically-trained touch typist, with a measured typing speed at one time of around 90 words per minute. Based on A Note on Calculating Text Entry Speed[^], that corresponds to (90 * 5) / 60 = 7.5 characters per second. 1.2GB of source code should therefore require only 5.45 years. Note that this result is based on Mom's typing speed measured on a mechanical typewriter keyboard. I don't have data, but it's reasonable to assume she would be faster on a modern electronic keyboard. She bought a refurbished IBM Selectric[^] typewriter when I was in high school, and I remember her claiming her typing speed increased substantially. Let's take a W.A.G. here and assume that an electronic keyboard gives you a speed edge of 25%, which then reduces the time for 1.2GB of code to 4.36 years. All of that is mere mechanics, however. Source code editors provide all kinds of productivity aids: text templates and snippets, predictive typing (IntelliSense), and so on. After I'd been using C# for a while, I found I'd modified my code editing habits to really take advantage of Visual Studio's predictive typing features. I wouldn't be surprised to be able to generate 1.2GB of source code in less than a year.**</BullshitWarning>**
Software Zen:
delete this;
-
Pshaw. One character per second? That's really slow for typing speed.
**<BullshitWarning>**
Let's use my 80 year-old mother as a test subject here. She's a classically-trained touch typist, with a measured typing speed at one time of around 90 words per minute. Based on A Note on Calculating Text Entry Speed[^], that corresponds to (90 * 5) / 60 = 7.5 characters per second. 1.2GB of source code should therefore require only 5.45 years. Note that this result is based on Mom's typing speed measured on a mechanical typewriter keyboard. I don't have data, but it's reasonable to assume she would be faster on a modern electronic keyboard. She bought a refurbished IBM Selectric[^] typewriter when I was in high school, and I remember her claiming her typing speed increased substantially. Let's take a W.A.G. here and assume that an electronic keyboard gives you a speed edge of 25%, which then reduces the time for 1.2GB of code to 4.36 years. All of that is mere mechanics, however. Source code editors provide all kinds of productivity aids: text templates and snippets, predictive typing (IntelliSense), and so on. After I'd been using C# for a while, I found I'd modified my code editing habits to really take advantage of Visual Studio's predictive typing features. I wouldn't be surprised to be able to generate 1.2GB of source code in less than a year.**</BullshitWarning>**
Software Zen:
delete this;
That is hilarious and an interesting way to look at code...that you type it and don't even think about what you are typing. :laugh: I set the 1 character/second rate (60 chars/minute) to account for the dev actually thinking about the code s/he is typing. But, you are correct, we know that devs don't actually think. They just type. :rolleyes:
-
That is hilarious and an interesting way to look at code...that you type it and don't even think about what you are typing. :laugh: I set the 1 character/second rate (60 chars/minute) to account for the dev actually thinking about the code s/he is typing. But, you are correct, we know that devs don't actually think. They just type. :rolleyes:
raddevus wrote:
That is hilarious and an interesting way to look at code...that you type it and don't even think about what you are typing
Thanks :-D. Most programmers understand the flow experience[^], where the code you're writing seems to come out of your fingers without a lot of thought. With the productivity aids I mentioned, and enabling the flow as much as possible, it's intuitive that you would get peak rates of source code generation some significant multiple of your non-flow rate. Irrelevant side note: I get migraine headaches. One of my precursor symptoms is emotional swings, like a rollercoaster version of manic-depression. I've written some really interesting, large chunks of code in a pre-migraine manic state. Some times it actually worked :sigh:.
raddevus wrote:
we know that devs don't actually think. They just type
10 GET "https://www.codeproject.com/Questions/ask.aspx","_programming task_"
20 GOSUB 1000 'copy
30 GOSUB 2000 'paste
40 GOTO 10Software Zen:
delete this;
-
No static data, but there are icons, resource files, which are still hand crafted, so it's OK to include them. So yeah, 10 GB of code. It is huge.
What about packages, e.g. NuGet?
"'Do what thou wilt...' is to bid Stars to shine, Vines to bear grapes, Water to seek its level; man is the only being in Nature that has striven to set himself at odds with himself." —Aleister Crowley
-
What about packages, e.g. NuGet?
"'Do what thou wilt...' is to bid Stars to shine, Vines to bear grapes, Water to seek its level; man is the only being in Nature that has striven to set himself at odds with himself." —Aleister Crowley
Nope, this is just our code. All that stuff if in a third party dir.
-
C++ say. I was just looking at the product I am working on and in total it has almost 1.2 GB of data in the project directories (after cleaning) HOw long would it take one programmer to write that much code?
Compare exe's. Then "function points": 1 input = 1 FP 1 output = 1 FP 1 Update = 1 FP 1 report = 1 FP etc. Then take the language "gearing factor" (average LOC per FP based on company history) to get a total LOC and adjusted to allow for the teams's risk factors (newbs, new tech, etc.)
"(I) am amazed to see myself here rather than there ... now rather than then". ― Blaise Pascal