|
Thread Rules 1. This is not a "do my homework for me" thread. If you have specific questions, ask, but don't post an assignment or homework problem and expect an exact solution. 2. No recruiting for your cockamamie projects (you won't replace facebook with 3 dudes you found on the internet and $20) 3. If you can't articulate why a language is bad, don't start slinging shit about it. Just remember that nothing is worse than making CSS IE6 compatible. 4. Use [code] tags to format code blocks. |
Here's my brief rundown on C++ Exceptions:
It's convenient to have a language feature as an approach to error handling. It has a 1%-20% overhead depending on who you ask, and significant memory footprint impacts for embedded systems. It's a terror as far as compiling time optimization goes, but theres no real way around that, apart from don't have errors to handle. Exceptions aren't sufficient for real-time programming. If you're writing a deterministic, real-time system, why would you ever want a feature that can hijack the thread of execution and delay it by an arbitrary amount of time in order to handle an error?
I probably have more to say about what kind of programs tend to use Exceptions than the Exception library features themselves. Personally, I can't say much about Exceptions in OOP besides that C++ doesn't have garbage collection and instead relies on RAII.
|
It looks like I'll be unemployed soon after graduation. I've had 2 unsuccessful online assessments for jobs (Graduate Software Engineer)
Test 1 1) Codility 2) Computing probability of events
Test 2 1) Calculation of data that is on graph, ratios, percentages 2) IQ test
Almost nothing about software or computers... I just don't know what I'm supposed to do. I'm starting to think that I may have to step down and apply for internship. I'd gladly take advice as well.
|
On March 28 2014 05:18 RoyGBiv_13 wrote:Here's my brief rundown on C++ Exceptions: It's convenient to have a language feature as an approach to error handling. It has a 1%-20% overhead depending on who you ask, and significant memory footprint impacts for embedded systems. It's a terror as far as compiling time optimization goes, but theres no real way around that, apart from don't have errors to handle. Exceptions aren't sufficient for real-time programming. If you're writing a deterministic, real-time system, why would you ever want a feature that can hijack the thread of execution and delay it by an arbitrary amount of time in order to handle an error? I probably have more to say about what kind of programs tend to use Exceptions than the Exception library features themselves. Personally, I can't say much about Exceptions in OOP besides that C++ doesn't have garbage collection and instead relies on RAII.
Wait, shouldn't you not ever throw exceptions in a RTOS anyways? so any exception implementation doesn't make sense? I might be wrong.
I think the SO post said that C++ Exceptions were bad because you could throw an exception which broke RAII. I don't find Google's overview satisfactory (like the arguments on SO said).
On March 28 2014 06:16 darkness wrote:It looks like I'll be unemployed soon after graduation. I've had 2 unsuccessful online assessments for jobs (Graduate Software Engineer) Test 1 1) Codility2) Computing probability of events Test 2 1) Calculation of data that is on graph, ratios, percentages 2) IQ test Almost nothing about software or computers... I just don't know what I'm supposed to do. I'm starting to think that I may have to step down and apply for internship. I'd gladly take advice as well.
I wouldn't be discouraged - I think you're not applying to a large enough variety of jobs. You've only talked about two that seemed like they were graduate studies programming jobs. There are tons of jobs in other industries that will have other kinds of (more relevant to what you seem to have talked about) interviews. You should be applying to a lot of interviews, like 20+ at least, and then organizing ones that you like. You might also want to take another look at how you're tailoring your resume (what kinds of employers are you trying to attract).
Internships though are really nice (if you have done them before) because you can get your foot in the companies' door easily, and the interview process is not as rigorous as it would be for a full-time position. You can get paid relatively well in comparison to full-times and still do relevant industry work (depending on the company). What jobs are you looking for, and what kind of experience do you have?
|
On March 25 2014 21:16 sluggaslamoo wrote:Show nested quote +On March 25 2014 19:07 endy wrote:On March 24 2014 20:04 sluggaslamoo wrote:On March 24 2014 19:04 endy wrote: Anyone has a nice framework to recommend to develop cross platform mobile apps? Most of them, like PhoneGap seem to be based on Javascript? Is Javascript powerful/robust enough? I don't think it can compare with a solid object oriented language.
edit: Also not very sure of how I can use a local database like Sqlite when using such a framework, or how to make my application work when offline. Appcelerator Titanium. Nothing else comes close. This looks pretty good, I will give this a try first. Thanks! On March 25 2014 01:59 Athos wrote:On March 24 2014 19:04 endy wrote: Anyone has a nice framework to recommend to develop cross platform mobile apps? Most of them, like PhoneGap seem to be based on Javascript? Is Javascript powerful/robust enough? I don't think it can compare with a solid object oriented language.
edit: Also not very sure of how I can use a local database like Sqlite when using such a framework, or how to make my application work when offline. If you're interested in game development, I recommend Game Closure. It's open source and they have a pretty good dedicated community to answering questions about the framework. Not interested in games for now, but thank you. On March 25 2014 18:25 Encdalf wrote:On March 24 2014 19:04 endy wrote: Anyone has a nice framework to recommend to develop cross platform mobile apps? Most of them, like PhoneGap seem to be based on Javascript? Is Javascript powerful/robust enough? I don't think it can compare with a solid object oriented language.
edit: Also not very sure of how I can use a local database like Sqlite when using such a framework, or how to make my application work when offline. Using JS is usually fine, however there are areas where a native implementation is better. But that depends on what you want to do. I used PhoneGap a while back for several Apps and it worked. I can't say anything about Appcelerator but I guess in the end it comes down to what do you need and which suits you better  As for making the app offline capable, you simply put all data into the app, and ship it with it. Or you download files on demand and store them in the app. As for database, the frameworks have a database api you can use. Hmm ok, I just feel that JS is fine for scripting as its name indicates. But I don't think you can write clean, easy to maintain and more importantly re-usable code with JS as you could with Java. Thanks! http://coffeescript.org/Java has pretty horrid code re-usability actually, but I think I've beaten the horse to death enough over that.
I would say it's harder to write good goode in javascript as it's a relatively unstructured language, but I believe that you can write cleaner easier to maintain code in javascript than in java. Java forces you to over-architecture things that can be done in a simple, lightweight, and easy to maintain fashion in javascript. The problem is that people don't understand javascript or don't know what tools and patterns they have at their disposal. If you use AMD along with the module namespacing pattern you can write very clean and maintainable code, look at the big Node.js projects, or jQuery.
|
On March 28 2014 05:18 RoyGBiv_13 wrote:Here's my brief rundown on C++ Exceptions: It's convenient to have a language feature as an approach to error handling. It has a 1%-20% overhead depending on who you ask, and significant memory footprint impacts for embedded systems. It's a terror as far as compiling time optimization goes, but theres no real way around that, apart from don't have errors to handle. Exceptions aren't sufficient for real-time programming. If you're writing a deterministic, real-time system, why would you ever want a feature that can hijack the thread of execution and delay it by an arbitrary amount of time in order to handle an error? I probably have more to say about what kind of programs tend to use Exceptions than the Exception library features themselves. Personally, I can't say much about Exceptions in OOP besides that C++ doesn't have garbage collection and instead relies on RAII.
can you give a more detailed rundown? i would be much interested.
|
@dae many thanks, I know where to look now.
|
On March 27 2014 16:06 obesechicken13 wrote:How do you debug a timeout in .net 4.0? ![[image loading]](http://i.imgur.com/DLbyakH.png) We deployed on amazon. This works when you run the site locally on amazon. It also works when I run the site on my machine in visual studio. I can't seem to find anything in the log files that might help. The problem is that nothing returns. No error code. It works if you make the app bind on port 80, but we have two different parts of the site that are currently running on different ports. I tried disabling the firewall but that didn't help. We edited Amazon's security groups to open port 81. Nothing.
I couldn't figure out how to put the calendar in as a subdomain.
So we're giving up on this approach. Thanks anyways everyone.
|
Just saw that you try to operate it from two ports.. Two ports are affected by same-origin policy, and you might to have to set e.g. CORS headers. Otherwise the ressources from the different port won't load and lead to a timeout
|
On March 28 2014 09:11 Blisse wrote: I think the SO post said that C++ Exceptions were bad because you could throw an exception which broke RAII. I don't find Google's overview satisfactory (like the arguments on SO said).
No, as long as you don't throw exceptions in destructors, you can't break RAII. The problem is that old code doesn't use RAII. That's also what the SO post says.
If you throw in destructors, you deserve the horrible death your program will die.
|
So,
I'm like fresh out of the box new when it comes to coding. I think I want to pursue it as a full time hobby hopefully leading into possible future employment. I've done all the OP said and have done otherwebsites such as codeacademy.com. I want to make an app for my phone android OS. What do any of you suggest for me to do as far as learning / practicing and a good project to do as a stepping stone to eventually reach my goal of making an app?
Sorry If i'm kinda breaking the chain of thought in this thread. You guys are awesome and I respect you guys for your skill immensely so was wondering what you think?
Oh and is there any website or program I can download to work with assembly language at all.... I tried the OP info and it was either book to buy or website not found.
Thanks for any reply
|
On March 29 2014 04:02 Pirfiktshon wrote:So, I'm like fresh out of the box new when it comes to coding. I think I want to pursue it as a full time hobby hopefully leading into possible future employment. I've done all the OP said and have done otherwebsites such as codeacademy.com. I want to make an app for my phone android OS. What do any of you suggest for me to do as far as learning / practicing and a good project to do as a stepping stone to eventually reach my goal of making an app? Sorry If i'm kinda breaking the chain of thought in this thread. You guys are awesome and I respect you guys for your skill immensely so was wondering what you think? Oh and is there any website or program I can download to work with assembly language at all.... I tried the OP info and it was either book to buy or website not found. Thanks for any reply 
If you're asking how to work with Assembly, then you may simply use the Inline Assembler in the C language. It's a really low level language. Do you really need it?
|
Well I don't need HTML CSS Java ruby python or C++ but I love it all so much I will literally learn anything I can about any language that I can get my hands on lol
|
Hello everyone. This is my first time posting is this thread so please be gentle. I will soon start my third year on a bachelor of software development, major in CS and I was thinking of getting into developing APIs. I'm half decent with C++ and Java and have dabbled somewhat in Python as well. Is there any career what so ever in developing APIs? Is there some particular skill/knowledge that could be useful?
|
On March 29 2014 06:10 gOst wrote: Hello everyone. This is my first time posting is this thread so please be gentle. I will soon start my third year on a bachelor of software development, major in CS and I was thinking of getting into developing APIs. I'm half decent with C++ and Java and have dabbled somewhat in Python as well. Is there any career what so ever in developing APIs? Is there some particular skill/knowledge that could be useful?
There sure is, but it's probably not the type of API's you think of. An API is just an interface between a programming language and something else. The Java/Python API you've worked with are implemented as language libraries, but these days, API development is done using client/server web model (The buzzword is REST, which stands for something that is no longer really true). Some examples are: Twitter's API Twilio's API
If you make a product, either on the web or a native application, and you want users to be able to interact with the program, you will need an API. If it's a native application, you can either write a plug-in library to implement the API (Think minecraft's plugin system), or run it as a client/server model (think databases). If it's a web service, then it's pretty much all RESTful APIs. This process of exposing an application to an interface that is programmable is how "platforms" are made.
My best example for a "API" that creates a "platform" is the Starcraft Map Editor, which exposed an API for a proprietary mapping language that changed Starcraft from a "game" to a "platform".
After reading this post, if you think "Gee, I think designing a platform is really nifty, and I would really want to make money doing it", then take a look at how Twitter and Twilio are building their API, and work your way in that direction, towards web backend. Try to remember me when you're diving into your Scrooge McDuck piles of gold that (good) web backend developers make.
If you're thinking "I don't know about all that web stuff, but platforms are really neat," then maybe you're just a language nut. That's okay too. There's a way to make money thinking about language definitions and library interfaces all day too. Try a compiler's class or operating system's class and see if you can dig on the Operating System level API, then work at Google or Microsoft (or i guess now Facebook with it's metaverse might be a good bet too).
On March 28 2014 11:10 nunez wrote:Show nested quote +On March 28 2014 05:18 RoyGBiv_13 wrote:Here's my brief rundown on C++ Exceptions: It's convenient to have a language feature as an approach to error handling. It has a 1%-20% overhead depending on who you ask, and significant memory footprint impacts for embedded systems. It's a terror as far as compiling time optimization goes, but theres no real way around that, apart from don't have errors to handle. Exceptions aren't sufficient for real-time programming. If you're writing a deterministic, real-time system, why would you ever want a feature that can hijack the thread of execution and delay it by an arbitrary amount of time in order to handle an error? I probably have more to say about what kind of programs tend to use Exceptions than the Exception library features themselves. Personally, I can't say much about Exceptions in OOP besides that C++ doesn't have garbage collection and instead relies on RAII. can you give a more detailed rundown? i would be much interested.
I'd love to do an investigation into Exceptions and their internals, but I probably won't get a chance for a while since it doesn't really come up with embedded stuff (for good reason). .
|
On March 29 2014 07:22 RoyGBiv_13 wrote:Show nested quote +On March 29 2014 06:10 gOst wrote: Hello everyone. This is my first time posting is this thread so please be gentle. I will soon start my third year on a bachelor of software development, major in CS and I was thinking of getting into developing APIs. I'm half decent with C++ and Java and have dabbled somewhat in Python as well. Is there any career what so ever in developing APIs? Is there some particular skill/knowledge that could be useful? There sure is, but it's probably not the type of API's you think of. An API is just an interface between a programming language and something else. The Java/Python API you've worked with are implemented as language libraries, but these days, API development is done using client/server web model (The buzzword is REST, which stands for something that is no longer really true). Some examples are: Twitter's APITwilio's APIIf you make a product, either on the web or a native application, and you want users to be able to interact with the program, you will need an API. If it's a native application, you can either write a plug-in library to implement the API (Think minecraft's plugin system), or run it as a client/server model (think databases). If it's a web service, then it's pretty much all RESTful APIs. This process of exposing an application to an interface that is programmable is how "platforms" are made. My best example for a "API" that creates a "platform" is the Starcraft Map Editor, which exposed an API for a proprietary mapping language that changed Starcraft from a "game" to a "platform". After reading this post, if you think "Gee, I think designing a platform is really nifty, and I would really want to make money doing it", then take a look at how Twitter and Twilio are building their API, and work your way in that direction, towards web backend. Try to remember me when you're diving into your Scrooge McDuck piles of gold that (good) web backend developers make. If you're thinking "I don't know about all that web stuff, but platforms are really neat," then maybe you're just a language nut. That's okay too. There's a way to make money thinking about language definitions and library interfaces all day too. Try a compiler's class or operating system's class and see if you can dig on the Operating System level API, then work at Google or Microsoft (or i guess now Facebook with it's metaverse might be a good bet too).
I guess I mainly was thinking about the platform/interface aspect you described. An interface that lets other programmers communicate with a service or product of some sort. So I basically have to decide whether I want to focus on Operating System APIs or web backends? I recently made an android application in which I used google play's map API. I think those kinds of API interest me the most, where the API uses the web to communicate with a backend to some sort of hardware.
|
On March 29 2014 07:47 gOst wrote:Show nested quote +On March 29 2014 07:22 RoyGBiv_13 wrote:On March 29 2014 06:10 gOst wrote: Hello everyone. This is my first time posting is this thread so please be gentle. I will soon start my third year on a bachelor of software development, major in CS and I was thinking of getting into developing APIs. I'm half decent with C++ and Java and have dabbled somewhat in Python as well. Is there any career what so ever in developing APIs? Is there some particular skill/knowledge that could be useful? There sure is, but it's probably not the type of API's you think of. An API is just an interface between a programming language and something else. The Java/Python API you've worked with are implemented as language libraries, but these days, API development is done using client/server web model (The buzzword is REST, which stands for something that is no longer really true). Some examples are: Twitter's APITwilio's APIIf you make a product, either on the web or a native application, and you want users to be able to interact with the program, you will need an API. If it's a native application, you can either write a plug-in library to implement the API (Think minecraft's plugin system), or run it as a client/server model (think databases). If it's a web service, then it's pretty much all RESTful APIs. This process of exposing an application to an interface that is programmable is how "platforms" are made. My best example for a "API" that creates a "platform" is the Starcraft Map Editor, which exposed an API for a proprietary mapping language that changed Starcraft from a "game" to a "platform". After reading this post, if you think "Gee, I think designing a platform is really nifty, and I would really want to make money doing it", then take a look at how Twitter and Twilio are building their API, and work your way in that direction, towards web backend. Try to remember me when you're diving into your Scrooge McDuck piles of gold that (good) web backend developers make. If you're thinking "I don't know about all that web stuff, but platforms are really neat," then maybe you're just a language nut. That's okay too. There's a way to make money thinking about language definitions and library interfaces all day too. Try a compiler's class or operating system's class and see if you can dig on the Operating System level API, then work at Google or Microsoft (or i guess now Facebook with it's metaverse might be a good bet too). I guess I mainly was thinking about the platform/interface aspect you described. An interface that lets other programmers communicate with a service or product of some sort. So I basically have to decide whether I want to focus on Operating System APIs or web backends? I recently made an android application in which I used google play's map API. I think those kinds of API interest me the most, where the API uses the web to communicate with a backend to some sort of hardware.
To be fair, you can use pretty much any language to implement a web backend to serve a RESTful API. You'll want to take a look at how data is transmitted over the internet. A typical way is to use JSON, and you'll also want to understand the layer the transport layer, OSI Model, and other networking concepts. Web companies tend to use a lot of Javascript to implement their APIs as well, so you may want to look into that.
The reason I point you in this technical direction, instead of in the architectural direction is because you will have to put in your due time to understand the backend of an API before you can grasp the limitations of what you can and can't do with a front end. An architectural decisions is what makes an API good versus bad, and how to make people actually start using your API
For example, I have a set of microchips connected via a low power wireless network. If I design my API to return a measurement of a sensor on these motes, they might get a flood of requests each second. Since it's a low power network, the requests will step on each other causing each request to take longer to get to the mote in the first place, and by then the data may be obsolete. Instead, I might have an POST request to give an address for the mote to stream its data to. Architecturally, this is just "do we poll the mote, or do we have the mote push data to us?" question, but without an understanding of the web, it's easy to think at too high of a level.
As for OS level APIs, its learning hardware and computer engineering instead of networking, and the API's are a good bit more complicated, but you have more room as your users will be understanding.
|
On March 29 2014 01:55 spinesheath wrote:Show nested quote +On March 28 2014 09:11 Blisse wrote: I think the SO post said that C++ Exceptions were bad because you could throw an exception which broke RAII. I don't find Google's overview satisfactory (like the arguments on SO said).
No, as long as you don't throw exceptions in destructors, you can't break RAII. The problem is that old code doesn't use RAII. That's also what the SO post says. If you throw in destructors, you deserve the horrible death your program will die.
Someone said if you throw an exception on a dynamically allocated object, you may end up not calling delete on it and that's a memory leak. They mentioned that auto-pointers in C++11 solves this issue. That's how I interpreted the argument against Google.
|
On March 29 2014 07:22 RoyGBiv_13 wrote: I'd love to do an investigation into Exceptions and their internals, but I probably won't get a chance for a while since it doesn't really come up with embedded stuff (for good reason). . blast.
|
On March 29 2014 11:22 Blisse wrote:Show nested quote +On March 29 2014 01:55 spinesheath wrote:On March 28 2014 09:11 Blisse wrote: I think the SO post said that C++ Exceptions were bad because you could throw an exception which broke RAII. I don't find Google's overview satisfactory (like the arguments on SO said).
No, as long as you don't throw exceptions in destructors, you can't break RAII. The problem is that old code doesn't use RAII. That's also what the SO post says. If you throw in destructors, you deserve the horrible death your program will die. Someone said if you throw an exception on a dynamically allocated object, you may end up not calling delete on it and that's a memory leak. They mentioned that auto-pointers in C++11 solves this issue. That's how I interpreted the argument against Google. std::auto_ptr has been in C++ for a long time. And RAII means that you don't use dynamic allocation out in the wild, but always in a controlled environment where there is a destructor of an object on the stack ready to clean up that dynamic allocation if an exception is thrown. auto_ptr can provide that destructor.
|
Ah right I forgot about auto being old since unique succeeded it, but I don't see how that relates to not using C++ exceptions.
Google's explanation seemed to be countered by the fact that you could use smart pointers but Google didn't use them initially so they don't support them when maintaining legacy code. So I still don't see why you shouldn't be using C++ exceptions if you're smart about it.
|
|
|
|
|
|