Programming Method - How are you getting around with it ?

Arch4ngel

Senior Contributor
Joined
Mar 22, 2004
Messages
940
Location
Montreal, QC
How do you program and plan your program !?

  1. "I don't know planning. I code and I use class when I'm forced to"
  2. "I plan somewhat a little. Have a few class that help simplify somethings but I do much code than plan"
  3. "I plan my whole project before I get on my computer. When I get in front of my computer to code, everything's (or nearly) work perfect and I have a lot of generic classes that I made which simplify a lot my work.
Which of them are you ?
Have you generic classes that you use often ? Are you making them ?
Are you taking time to plan a software ?
 
Well, for a succesful project you need to plan everything, even what was not supposed to be planned, the steps for me to start a new project with the teams are:

1. Understand the needs sent by email, I call the guy who sent me the request and spend with him sometimes up to 2 hours understanding what he wants, if he lives close to SD I go to the office and sit there with him to do the same, understand what he needs.
2. Create the team for the development, I usually choose a Senior Developer, a Junior developer or two or three or ten, dependes on how big the project is, a DBA (usually is the same DBA in this office for all the projects), and me.
3. Make the complete analysis of what they do at this moment, and then create the proposal for the solution, for the analysis the developers (usually the senior developer) go with the users and sit with them to understand what they do.
4. We make presentations on the proposal for the users, explain to them what we're proposing, sell the solution to the users (at the end, they'll be the ones using it).
4. After the proposal has been accepted for the management of the company (a process that can take up to 1 month) we make the design of the application and the database, this can take up to 2 months, the whole team participates, giving ideas, telling the expierence they have with other solutions, etc.
5. After up to 6 months of planning, analysis and design we start developing, and at the middle of the development we evaluate how is it going, sometimes we need to go back to the design stage.

I'm talking here for really complex solutions, for a simple one, we take the team that already works with the application and make 'em create the solution.When we feel ready we deploy a BETA version of the application for the user to test it.
For us development is pretty serious and not just start typing code.
 
Damn... it's what I've seen in school ! Hehe.
I was more talking about solo programming (at home or something for fun).

But this is really interesting. Particulary the part on the composition of the developpement team (really interesting... not seen that really in school).

Other proposition ? (more on solo programming... because we all know that someone who don't make plan for a big project is... simply blind or stupid)
 
years ago, I used to code solely. In house and even in works. Since I was new to software world, I didn't aware on the quality of software. I code based on any logic I could think of and any trick I can hidden off.

Until one day, my school tought me about Software Metrics. I went home and open back all the software that I had developed. Oh, my god. I finally realised that the software written by me were totally OUT. cannot maintain at all. The luckiest thing was that all the projects before that are stand alone system and their scopes are not so big.

I started to think on a way to achieve a standard on my software after that. Few approaches had been taken by me in order to achieve the quality.

Nowadays, I am dealing with bigger projects. I still working alone. Anyhow, I always struggling myself on software planning. This is really the main key to achieve a quality software. As what iebidan said, I am really support the point of "development is pretty serious and not just start typing code".

Not only planing on how to code, but also the databases, the user interface, the network connection, the backup server/databases, and exception handling and a lot more...

So, how do u guys think? You always seek for quality and standard for your systems?
 
I come somewhere between 2 and 3. I try to plan as much as possible but I usually find gaps in my plan once I start work on development.
 
I plan more than before but just like TechnoTone ... I found gaps sometime and I jump analysis part. Or sometime ,when the problem isn't too big, I code and I simplify my code by making sub-functions, procedure and other class to ease the comprehension and the maintenance.
 
I'm closer to #1.

Took my first programming course 2 years ago and started programming 1.5 years ago. Just got my Associates Degree (2yr) in programming.

Unfortunately I seemed to have been one of the more talanted students in class. I didn't need to plan for anything. Any assignment we had, I would just do. I finished a two course book in one course and took on special assignments the second semister.

When we did planning in class, if the teacher let the students do the planning, I often just mapped out the plan in like 5 minutes.

Because of this, I'm more of the #1, which is the worst. I havn't done a very large project until the one I'm currently working on. I started to plan a little, then started. :(

I'm constantly writing up workaround Subs, changing older subs with overloads and parameters to get them to have more functionality. If I'd planned properly up front, I'd probobly be done with this program already.

I really do want to learn how to plan out larger scoped programs, were to start on a program thats 8 forms and a database (or two).

I saw mention of Software Metrics up above and I'm going to Google it, but if anyone has any advice or knows of any books that would help me out, I'd really appreciate it :D
 
Danaes: DON'T GET COCKY ABOUT THAT.
When I'd my courses and at school I developed everything in like 4 minutes, there were no planning or analysis, they're just teaching us the language and maybe some tricks, I think my knowledge and understanding on development and languages is pretty good, but I can't compare for example against Divil, he knows a lot more than me, or other guys here in the forums. NO ONE KNOWS EVERYTHING, and I use their help to solve some problems.

When you come up with a project that involves 4.5 million database transactions every day, database replication, databases with tables with more than 15 million rows (and growing), really complex stored procedures, functions, slow data links and a solution with 30 or more projects in it, you'll understand why you need to plan and design everything before starting, you'll understand why testing is so important in the lifecycle of your application. When you talk about a small app for 3 users who will add 100 records in 1 month to the database you don't have too much to do, but imagine an app that is used in 13,000 locations around the country, how do you deploy that?, you need to plan and design a deployment process for the application, the error that makes the application to crash will affect the other 12,999 locations, how will you solve the problem, update all the locations and how long your response time will be? see why in large projects you need to plan, design and then code? and sometimes go back to the start point and do some things again
It's not just type and then see, first you need to see and understand and then type. When you don't plan and just type, later your app will be so complex that will be a titanic effort to mantain it.
Cheers!!!!
 
iebidan said:
Danaes: DON'T GET COCKY ABOUT THAT.

I'm not cocky about that. I was one of the top three in my class, but I know nothing about programming (theory and code) compared to the majority of regulars on this board :D

I mentioned it, not because I'm cocky, but because I had an advantage over my classmates which is turning into a disadvantage.

I never got in the good habits because I just never needed to. The tasks and projects were never large enough to warent that kind of planning. I think there was one project were I spent like an hour because it was all about recursive functions and loops within loops, which hurt my head for a while until I got the hang of it. Even still, I mostly got through that project by doing it over and over and seeing what results I got.

I think thats okay to do with a single function/routine if you need to test something, but its crazy to do that sort of testing involving dozens to hundreds of lines of code.

When I'd my courses and at school I developed everything in like 4 minutes, there were no planning or analysis, they're just teaching us the language and maybe some tricks, I think my knowledge and understanding on development and languages is pretty good, but I can't compare for example against Divil, he knows a lot more than me, or other guys here in the forums. NO ONE KNOWS EVERYTHING, and I use their help to solve some problems.

Same here. Divil is the man! So are most of the other users. Most people have a niche where they're the masters or at least very good and then reasonably well rounded in other areas. I'm good in some areas, but I don't excel in any of them, by comparison of the real masters on this board.

When you come up with a project that involves 4.5 million database transactions every day, database replication, databases with tables with more than 15 million rows (and growing), really complex stored procedures, functions, slow data links and a solution with 30 or more projects in it, you'll understand why you need to plan and design everything before starting, you'll understand why testing is so important in the lifecycle of your application.

Dude, my application would be like a mini version of 1 of the 30 projects in your grand solution and it still makes me feel that way.

I can chalk up a lot to my time consumption to having to learn new aspects as I go (like learning ADO.Net), but really, I didn't plan and I would probobly be done if I had.

It's not just type and then see, first you need to see and understand and then type. When you don't plan and just type, later your app will be so complex that will be a titanic effort to mantain it.
Cheers!!!!

Yes, I know. I'm writing functions, then adding more. I have a lot in a public module (I know, thats bad practice) to be accessable throughout multiple forms, then I keep adding more, then altering some a bit, then adding overloads of the same thing, then getting further and removing an aspect, etc.

I'm not saying in any way that planning is bad. I'm saying that I fell into what I would think is a common pitfall for young programmers. You see the programming, it looks easy. You do it, easy. Then you try a really hard program and its like climbing a mountain because you didn't plan.

If anyone has any knows of any advice, links or books that could help me out, I'd be appreciative.

The best book that will be helping me is Object Oriented Programming with Visual Basic.Net. Its got a lot of the mechanics that would help with OOP (well, probobly all the mechanics really) but I need some theory books/tutorials/essays/etc on how to best organize code, how to plan for it, etc.
 
Daneas, Software Metrics is a set of formula, which is used to calculate any aspect of any software in term of quality and standard.

For example, TotalLineOfCodes/TotalFunctions could give us an idea of average lines in every functions.

We could even estimate how much time needed to be used for retrieving, adding and manipulating records. E.G:
Min Loop = 1 cycle, Max Loop = 1000 cycle,
So, we could estimated the time as 1000 X 0.01second.

Other than that, we could use software metrics to calculate the cost of a software. Anyway, Software metrics is not really mature at the moments. More studies had to be brought into studies, I think.

Daneas, Software Metrics is used to evaluate software system after the development. So, we could know where is our disadvantages and try to avoid these weaknesses in the coming projects. You will get more and more mature in your planning with Software Metrics. And, if you wish to have more understanding on Software Metrics, try to find it in Software Engineering books. For software planning, try to get Software Analysis and Design and Software Management books.
 
I'd be 3

...but often I am being forced by the client (the guy who got the $'s (actually euros)) to speed up developement: they want to see the program running - no matter how good it was planned. Not like I was doing it too slowly (coding about 12 hours per day nolife) but for example this project I'm currently working with was ordered like a year ago. :)

The previous coder failed few other projects badly (let's say the VB6 code was some peace of crap - nevaheard of classes, copy-pasting code rocks!), and now the clients are shimmering my *** for his inability (bugs, crashes, database is all messed, missing options that were in the contract etc).

Now it's looking a bit lighter since most of the old crap projects' bugs are fixed (temporary solutions, just to make it work until I do a rewrite) and apps are somehow working, in use by the end users. Now I got my chance create & plan something of my very own - this rewrite of one of the older apps would definitely be 3... You have no idea how good the inherited classes & stuff feel after 4 months of fixing someone else's bugs. ;)

Though, I just got a call from the client that they would like to see some testable beta this weekend... need to speed up things a bit and finish the mysql table structure quickly, so they can see what they want. *sigh*

Enough crap talk for tonight, back to coding ->

edit: euro char not showing up
 
I don't plan every single thing... but I make a lot of Visio schemas, flow charts and SB charts, for the most complex lines of code.

Instead of doing a very complex and detailed paper preview I usually write the comments of the code I will write before it's actually wrote...

When speaking of classes I have a lot of classes, ExtendableProperties and such that I allways re-use...

Alex :p
 
AlexCode said:
Instead of doing a very complex and detailed paper preview I usually write the comments of the code I will write before it's actually wrote...

Writing comments seems like a good idea.

Also similar to interfacing, you could create all of the procedures, but none of the code within.

[quoteWhen speaking of classes I have a lot of classes, ExtendableProperties and such that I allways re-use...

Alex :p[/QUOTE]

I'm scared of this now... after a post here, people are telling me that it's common practice for a company to ask for full rights to your code. I think that would put a dampner on code reuse if you can't reuse the dll's or classes you used to create said program.
 
Programmers/Developers who just leave school know NOTHING about design and analysis.

Design pattern? MVC? What the hell is it? lol :D

It is simply because they don't need to handle complex project. Only when they need to build complex stuff, they will start to recognize how important software engineering is.
 
As i read through these post i realize that most people get a lot more time for planning than we are. For example we had to do a re write on an old vb6 program that looked niced but did not work correctly (Filled with gotos need i say more). We had three weeks to re write this sever and client app( The old one took a year and a half to write.).We ended up taking 6 weeks.We were given no time for planning. I would love to do more planning but alas no time.
 
as to rewrite anything that is already existed doesn't need that much of planning.

Know why? because all the logic flow and process flow is been defined before. Re-writing is just copy and paste old idea with a little bit modification.

I used more than half year to write a POS and Inventory in vb6. Last month, I rewrote it in .net with only three weeks.

you could see this, how fast a development can be if a planning is defined clearly.
 
A redesign when moving from VB6 to .Net may extend the schedule but it could allow you to take full advantage of .Net features that didn't exist in VB6 (inheritance, delegates, new collection classes etc), as well as being able to remove many API / OCX / COM DLLs that were required to implement things that are now native to .Net.
 
The small problem here was i could not use the previously coded logic. The codeing was a mess and the app was split into four databases .It was a client sided that we had to change into a server and client app .We also had to created stat webpages for the application. So basicly it was writing it from scratch.
 
Original timeline: 18 months.
Your timeline to re-write: 3 weeks

Sounds like not a total re-write, but a strong need for Refactoring!

I picked this book up a few months ago and it has been fantastic! I knew many of the techniques described, but the author's insights in the first 2 chapters are worth every penny.

If you had a bit more time, then using some Design Patterns (or Design Patterns Explained) will greatly help you out.

When using Design Patters and Refactoring together, you can lessen the amount of up-front planning. No more worries about getting the design exactly right the first time. You still need some planning - but you don't have to (and shouldn't!) plan for everything.

-Nerseus
 
Back
Top