Lines of Code in an hour?

For everything that's not in any way related to PureBasic. General chat etc...

How many Lines of (BUG FREE) PB Code do you write in an hour?

< 10
5
13%
10 - 49
11
28%
50 - 75
4
10%
76 - 99
2
5%
> 100
3
8%
> 200
4
10%
> 300
4
10%
> 400
1
3%
> 500
6
15%
 
Total votes: 40

User avatar
Rescator
Addict
Addict
Posts: 1769
Joined: Sat Feb 19, 2005 5:05 pm
Location: Norway

Post by Rescator »

Either this is a trick question, or I misinterpreted the question.

I however answered the poll as if the question was,
how many lines of bug free code consecutively (sp?) do I on average code during 1 hour of work.
Which is between 10 and 50 lines and I mess up a line or two, then another 10-50 lines before next bug.

If however it asks how many lines of bug free code total in one hour of coding, then I got no clue really.

I have written full programs in a hour before, which had no bugged code.
And I have also managed to write a single and bugged line of code only, in a full hour. A very ambigious question in this case.

If this is a trick question, then I'm not really sure what it's hinting at.
Typing speed, typing speed of bugs, or what?
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6172
Joined: Sat May 17, 2003 11:31 am
Contact:

Post by blueznl »

i based my number upon some code that i wrote in the past, some of them over 6000..10000 lines long, and compared that with the time needed to wrote and debug them, so yes, i interpreted as 'bugfree code' not bugfree lines...
( PB6.00 LTS Win11 x64 Asrock AB350 Pro4 Ryzen 5 3600 32GB GTX1060 6GB - upgrade incoming...)
( The path to enlightenment and the PureBasic Survival Guide right here... )
techjunkie
Addict
Addict
Posts: 1126
Joined: Wed Oct 15, 2003 12:40 am
Location: Sweden
Contact:

Post by techjunkie »

Am I too old for this forum?!? :lol:

Lines of bugfree code in an hour, was a "common" measurement to explain quality, complexity, speed or difficulty of, for example a project, for 10 - 20 years ago.

It was said that 6 - 10 bugfree lines of code per hour (or was it DAY?!?! :lol: ) was average for a good programmer.
Image
(\__/)
(='.'=) This is Bunny. Copy and paste Bunny into your
(")_(") signature to help him gain world domination.
Kale
PureBasic Expert
PureBasic Expert
Posts: 3000
Joined: Fri Apr 25, 2003 6:03 pm
Location: Lincoln, UK
Contact:

Post by Kale »

I've just coded a completely cross platform flexographic utility for PC and Mac which automatically draws CAD keylines. It contains 2000+ lines of (bug free) code and took me about 18 hours. 111 lines per hour if i'm not mistaken. Try that in C++! :lol: i love PB! :D
--Kale

Image
josku_x
Addict
Addict
Posts: 997
Joined: Sat Sep 24, 2005 2:08 pm

Post by josku_x »

I can get more than 400 lines of code in an hour without bugs, copy paste or VD. It's the design which takes many lines of code. I also use a lot of API.. and nearly all my sources are uncommented.
User avatar
Joakim Christiansen
Addict
Addict
Posts: 2452
Joined: Wed Dec 22, 2004 4:12 pm
Location: Norway
Contact:

Post by Joakim Christiansen »

But anyway... it's the result that matter! :wink:
User avatar
Guimauve
Enthusiast
Enthusiast
Posts: 742
Joined: Wed Oct 22, 2003 2:51 am
Location: Canada

Post by Guimauve »

Ok let me try :

89 lines of bug free code in 0.0016 seconds

89/0.0016=x/3600

x = 200 250 000 lines of bug free code per hour

A small code snippet ...

Code: Select all

; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
; <<<<< Déclaration de la Structure >>>>>

Structure Vector3D

   i.f
   j.f
   k.f

EndStructure

; <<<<<<<<<<<<<<<<<<<<<<<<<
; <<<<< Les mutateurs >>>>>

Macro SetVector3Di(ObjetA, P_i)

   ObjetA\i = P_i

EndMacro

Macro SetVector3Dj(ObjetA, P_j)

   ObjetA\j = P_j

EndMacro

Macro SetVector3Dk(ObjetA, P_k)

   ObjetA\k = P_k

EndMacro

; <<<<<<<<<<<<<<<<<<<<<<<<<<<<
; <<<<< Les Observateurs >>>>>

Macro GetVector3Di(ObjetA)

   ObjetA\i

EndMacro

Macro GetVector3Dj(ObjetA)

   ObjetA\j

EndMacro

Macro GetVector3Dk(ObjetA)

   ObjetA\k

EndMacro

; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
; <<<<< Le Mutateur Update simple >>>>>

Macro UpdateVector3D(ObjetA, P_i, P_j, P_k)

   SetVector3Di(ObjetA, P_i)
   SetVector3Dj(ObjetA, P_j)
   SetVector3Dk(ObjetA, P_k)

EndMacro

; <<<<<<<<<<<<<<<<<<<<<<<<<<<<
; <<<<< L'Opérateur Plus >>>>>

Macro PlusVector3D(ObjetA, ObjetB, ObjetR)

   SetVector3Di(ObjetR, GetVector3Di(ObjetA) + GetVector3Di(ObjetB))
   SetVector3Dj(ObjetR, GetVector3Dj(ObjetA) + GetVector3Dj(ObjetB))
   SetVector3Dk(ObjetR, GetVector3Dk(ObjetA) + GetVector3Dk(ObjetB))

EndMacro

; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<
; <<<<< L'Opérateur Minus >>>>>

Macro MinusVector3D(ObjetA, ObjetB, ObjetR)

   SetVector3Di(ObjetR, GetVector3Di(ObjetA) - GetVector3Di(ObjetB))
   SetVector3Dj(ObjetR, GetVector3Dj(ObjetA) - GetVector3Dj(ObjetB))
   SetVector3Dk(ObjetR, GetVector3Dk(ObjetA) - GetVector3Dk(ObjetB))

EndMacro

; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
; <<<<< Code généré en : 16 ms <<<<<
; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
Or a small variant ...

Code: Select all

; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
; <<<<< Déclaration de la Structure >>>>>

Structure Vector3D

   i.f
   j.f
   k.f

EndStructure

; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
; <<<<< Les Macros d'accès direct >>>>>

Macro Vector3Di(ObjetA)

   ObjetA\i

EndMacro

Macro Vector3Dj(ObjetA)

   ObjetA\j

EndMacro

Macro Vector3Dk(ObjetA)

   ObjetA\k

EndMacro

; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
; <<<<< Le Mutateur Update simple >>>>>

Macro UpdateVector3D(ObjetA, P_i, P_j, P_k)

   Vector3Di(ObjetA) = P_i
   Vector3Dj(ObjetA) = P_j
   Vector3Dk(ObjetA) = P_k

EndMacro

; <<<<<<<<<<<<<<<<<<<<<<<<<<<<
; <<<<< L'Opérateur Plus >>>>>

Macro PlusVector3D(ObjetA, ObjetB, ObjetR)

   Vector3Di(ObjetR) = Vector3Di(ObjetA) + Vector3Di(ObjetB)
   Vector3Dj(ObjetR) = Vector3Dj(ObjetA) + Vector3Dj(ObjetB)
   Vector3Dk(ObjetR) = Vector3Dk(ObjetA) + Vector3Dk(ObjetB)

EndMacro

; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<
; <<<<< L'Opérateur Minus >>>>>

Macro MinusVector3D(ObjetA, ObjetB, ObjetR)

   Vector3Di(ObjetR) = Vector3Di(ObjetA) - Vector3Di(ObjetB)
   Vector3Dj(ObjetR) = Vector3Dj(ObjetA) - Vector3Dj(ObjetB)
   Vector3Dk(ObjetR) = Vector3Dk(ObjetA) - Vector3Dk(ObjetB)

EndMacro

; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
; <<<<< Code généré en : 15 ms <<<<<
; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
With a small tool I currently develop named Macro WorkShop.

Regards

Guimauve
josku_x
Addict
Addict
Posts: 997
Joined: Sat Sep 24, 2005 2:08 pm

Post by josku_x »

Guimauve wrote:89 lines of bug free code in 0.0016 seconds
WOW! THat sounds just too impossible! Are you a Matrix guy? :)
Anden
Enthusiast
Enthusiast
Posts: 135
Joined: Mon Jul 21, 2003 7:23 am
Contact:

Post by Anden »

There is no such thing like "BUG FREE Code" :cry: :cry:
josku_x
Addict
Addict
Posts: 997
Joined: Sat Sep 24, 2005 2:08 pm

Post by josku_x »

Yes, you are correct every code IS a BUG. But a BAD BUG is code which for example freezes the OS even if it's not attempted to do that.
User avatar
Guimauve
Enthusiast
Enthusiast
Posts: 742
Joined: Wed Oct 22, 2003 2:51 am
Location: Canada

Post by Guimauve »

josku_x wrote:
Guimauve wrote:89 lines of bug free code in 0.0016 seconds
WOW! THat sounds just too impossible! Are you a Matrix guy? :)
No ! As I said before. I have programmed a small tool capable to write some code for me. It's extremelly fast and bug free code.

Regards
Guimauve
josku_x
Addict
Addict
Posts: 997
Joined: Sat Sep 24, 2005 2:08 pm

Post by josku_x »

WRONG! As I said above every code is a BUG-. :D
Post Reply