As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
I'm going to be teaching a scripting and tool development class to a group of 3D animators. In amongst teaching them coding fundamentals, I plan to have them pick a repetitive task they must perform frequently and have them iteratively develop a tool to automate or simplify this task as an assignment.
What I'd like to know are some criteria that can be used for grading programming assignments such as these? Some of the criteria I came up with were:
Does It Work - Does the tool perform it's task, does it break on certain cases, etc.
Code Cleanliness - Has the code been properly indented, is their coding style consistent, etc.
Documentation - Are functions well documented, are any "clever" bits of code commented, is it under-commented or over-commented, etc.
Efficiency - Has the script been optimized to run quickly, has a lot of unnecessary optimization been done on a task that isn't run very often, etc. (This one I'm not going to put to much emphasis on since these aren't professionally developed tools usually the tool working is more important than speed)
Are there any others?
Clarity. It's important that their code be comprehensible to anyone competent who should chance to open the file.
Does the way the student went about the exercise indicate that they have paid attention to what was taught in class?
You are right to look beyond "does it work"; look for general approach and "craftsmanship".
Do you teach the importance of testing? Look for test cases.
If they had freedom to choose their tools, did they choose wisely?
(no plagarism, obviously)
Are the invariants documented? Are there any unit tests?
Is the entire script broken up into modules or other units of about the right size?
(The inability to break up codes of over 100 lines is a bugbear of beginning programmers.)
Tell Them how it is going to work in terms of file locations etc. Provide one set of data for Them to test ón and another for testing their solutions.
Related
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
Recently I've started on a project which requires a Cortex M3 processor.
I have some previous experience with 8bit AVR microcontrollers, so I was hoping for a not to big transition.
So I've bought a STM32L-Discovery kit (since low power is an important point) and started looking at some examples.
However, I'm completely stuck at the beginning.
When programming with AVR it was all very straightforward, just by including 2 or 3 files it was possible to write a simple main.c for like say a blinking LED.
However the examples in IAR EWARM (which I'm using) all look very bloated, lots of files which make it difficult to start. I'm having the same problem with most online tutorials.
Does anybody know any (very) simple tutorials which might help me. I'm thinking about purchasing "The Definitive Guide to the ARM Cortex-M3" since it seems highly recommended.
This might be a very dumb question but I'm stuck for too long now and I'm feeling a bit desperate.
I completely agree with you. I am also starting out and I find it difficult to even scratch the surface! I have some good experience with PICs, but with ARMs the learning curve is really steep.
For the STM32F4Discovery I am using, ST provides a number of examples. Starting from simple pin toggling. I am going through the main.c file which for every example is well commented, and try to understand from there. They have a peripherals library, so locate that and look into the declarations of the functions. I learned a few things like that.
Also make sure you reference the actual manual of the ARM you are using.
I think it boils down to how much time you have to spend. Speaking for myself, I don't have the time to go through the manual and understand how everything works. If you do find some good sources please post them!
In closing I am pasting a couple of urls I am found useful information:
http://www.hitex.com/index.php?id=download-insiders-guides
http://www.micromouseonline.com/category/stm32/#axzz1wMO2VjAI
I would suggest using CMSIS and standard peripheral library for programming ARM Cortex. Here are some tutorials on how to set up things and start writing code:
http://www.embedds.com/arm-cortex-tutorials/
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
well lot of forums and even this site is full of questions where people don't use any framework(whetever language they use) and they are stuck on code for common tasks like logins,database accesses,etc while frameworks provide code that works correctly for these routine tasks. Then why do people still go without frameworks? i want to know this because i am trying to build something of substantial scale so i was deciding if i really need a framework or a homegrown solution would be better? a homegrown solution can be a great learning experience but is there something more to it?
Some reasons:
Some tasks are so small that it's easier to do them without a framework, which:
would have to be bundled;
would take up an order of magnitude more space than the app itself;
would impose a lot of requirements both for the app and the hosting platform;
would provide unnecessary overhead because of a lot of features which are unused in the particular app;
Wanting to find out about how things work;
Homework assignments;
Not being able to use the framework for some reason (constrained space, not enough permissions, etc.)
Not knowing about these frameworks;
Reducing dependencies on external libraries;
Legacy reasons (the app is old, it was started before any serious frameworks were out);
People go without framework for several different reasons, in my opinion the choice of developing in-house functionality is not always a bad choice.
Frameworks often don't implement all functionalities required but often add extra functionalities that will never be used making the code base unecessary "bloated".
Implementing a framework often requires a steep learning curve and often it is easier to implement certain functionality in house.
However often a framework can be the best choice but developers jump into coding without doing enough research beforehand.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
I have come across a fair bit of information on CI being a really flexible framework. Does Yii also allow great flexibility? And the ability to pick and choose when to use it or your own php?
Flexibility is very subjective, so this question is a bit vague.
From my experience I can tell you that Yii is very very powerful, but in most cases when you want to go into really advanced territory you have to do things "Yii's way". If you do, you will find that the pieces of the puzzle click together really well and things go smoothly. If you don't (because presumably you haven't realized yet what "Yii's way" is), it's going to give you a hard time.
I am using YII since 2 years. I use it with combination with Zend AMF and create backend systems for Flash campaigns, create HTML5 webpages, simple pages, different competition pages and and find it usable for every case you need. The main advantage that it is really structured, logical and fast. So because of that I am spending my time on creating application logic, not on setting up environment, setting up all requests, pages, subpages etc., MVC model + ActiveRecord saves my time here.
I have been using Yii for a year now and find it very flexible. You can add your own methods to any model or write components outside models. You need to be familiar with the MVC structure, Object-oriented programming and for writing components, you need to know how to register the component in the config file and how to call it the Yii way.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
We have this legacy image viewer component in our project that's working fine but it's source is a real mess. I have to add a new feature to this component so that people can add annotation to images using a light pen which is not a complicated task per se but could be a nightmare dealing with our existing code.
I'm really confused right now I don't know where should I start . do I have to refactor the existing code?if not what else can I do?
So here's my question: What could be the best (less painful) approach dealing with such situations?
The question is not an exact duplicate, but this exact same answer applies (you just have a list of one change)
https://stackoverflow.com/questions/1386824/hired-as-a-developer-to-maintain-and-update-current-code-base-no-docs/1386844#1386844
Write lots and lots of tests that will allow you to verify that changes you make to the system do not change or break existing functionality.
These tests are like the brace-work that is used to support a physical building when a construction crew is doing reconstruction. That brace-work is used to keep the existing infrastructure intact. You need to preserve the infrastructure of your system with as many unit and integration tests as you have time to write.
These tests will allow you to make small, iterative changes to the system and easily verify that those changes still maintain the expected behavior.
You should read this very good article Big Ball of Mud. And for your answer we all get a big ball of mud at some point and we need to add new functionality to it. Re-factoring such a code is not a good idea since it require alot of testing. But adding few new lines will not harm it. So unless you have alot of time and so does the tester just add the new functionality to your existing code. Although the current code look messed up but remember it works and tested. Read the article and makeup your mind as to which approach is good.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
What is the difference between custom building a CMS website and an open source CMS?
If you build the CMS yourself you have the great opportunity of going through all the problems and bugs that have already been encountered and fixed by the people the build open source CMS before. ;-)
Seriously, in my opinion, building your own CMS only makes sense if there is no open source CMS that you can customize to fit your needs. I think that you will have less trouble (and it will take less time) customizing some existing CMS.
Depends on what you need, how much time you have and how much coding experience you have. For example you could go and write your CMS, add only the functionality you need and keep it rather simple. But you'll have to debug it, take care of many issues like character encoding, security and you'll have to write even simple functionalities like an internal search engine. If you use something like Joomla, Wordpress or Drupal (just to mention the most popular ones), you'll have very well tested environments that have been patched for many security issues. You'll find hundreds of extensions like photo galleries, search engines, multiple language support. The drawback is that if you want to add something particular you have to spend time learning their API... but probably that would require less that coding something on your own... or may not. It's all about the complexity of what you need. You should try taking a look at one CMS API, I suggest a popular one so that you'll find plenty of examples on Google, then try to figure out how difficult it can be to learn and finally make your decision.