• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

How to Think Like a Computer Scientist: helps a C++ programmer?

 
Greenhorn
Posts: 3
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have been a software engineer for many years primarily working in C++.
I have just started working on a web application project where I need to write front end Java code that will interact with back end C++ code.
As I am still new to Java, I feel a bit frustrated working in Java since I find situations where it seems too restrictive compared to C++ which gives users the ability to pass pointers to methods for easy data manipulation.

It could be that I am no longer thinking like a modern day computer scientist and instead rely on old school manual memory management.
I would like to know if your book would help a C++ programmer like me get up to speed with Java to be more productive?
 
Marshal
Posts: 69843
278
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the Ranch

Many people nowadays think that an automatic heap with garbage collection is much more reliable than malloc and free.
You can have the best of both worlds by using JNI, though I can never seem to get JNI programs to work. I try JNI and get the worst of both worlds
There are not many books intended for C++ developers moving to Java┬« that I know about, but one which does take cognisance of C++ and which is a favourite of mine is Core Java II by Cai Horstmann. Only vol I of the latest edition is available just now, but vol II comes out in August (I think). Older editions were co‑written with Gary Cornell.
 
Author
Posts: 14
6
Postgres Database Java Linux
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Thomas,

Yes, I think the book would be very helpful to you -- not to learn how to program for the first time, but to see how beginners learn Java. I imagine you'd be able to read through the book very quickly and get straight to the exercises. We don't talk a lot about memory management, since as Campbell pointed out, it's more or less automatic. But Java allows you to pass references (pointers) to methods to manipulate data. It is more restrictive, but exactly in ways that simplify features of C++ that confuse people of all experience levels and often lead to hard-to-find bugs.

--Chris
 
I need a new interior decorator. This tiny ad just painted every room in my house purple.
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic