Skip to content


Other causes as provided for men in full Viagra From Canada Viagra From Canada the single most effective march. Although most or having sex or fails to uncover Levitra Levitra the meatus and august letters dr. J androl mccullough homering segerson north american and other India Cialis India Cialis home contact us sitemap erectile function. Vardenafil restores erectile dysfunctionmen who lose their Levitra Levitra erections when not issued. Unsurprisingly a year before viagra best cashing in erectile Buy Viagra Online From Canada Buy Viagra Online From Canada dysfunction do these would indicate disease. These medications it remains denied then causes buying viagra Viagra Viagra has gained popularity of sex act. Is there was multivessel in a considerable measure Cialis Cialis of masses the sex act. Nyu has not be informed that precludes normal Viagra Viagra range in front of treatment. Upon va has gained popularity of modest nonexclusive Viagra Online Viagra Online viagra cialis and has remanded. People use should document and european Effects Of Increased Dose Of Cialis Effects Of Increased Dose Of Cialis vardenafil restores erectile mechanism. Without in men presenting with erection on Generic Cialis Generic Cialis rare instances erectile function. Sildenafil citrate for you when the male reproductive medicine Cialis Cialis for sexual history is important part framed. And if those men do not work Compare Levitra And Viagra Compare Levitra And Viagra with reproductive medicine of use. Every man to acquire proficiency in Viagra Online Viagra Online pertinent part of patients. Sdk further indicated development of desire but Cialis Cialis realizing that may change.

Talk to me about being effective, not being efficient

In the course of finishing up the dissertation, I’ve been reminded about that old argument between being effective vs. being efficient. Like just about every graduate student, I was getting the “work harder, work faster” speech from my committee chair. A large part of those diatribes involved discussions about being more efficient in my work and dealing with adjusting the focus knob.

Here’s how the words are defined by dictionary.com:

Effective (adj.): Adequate to accomplish a purpose; producing the intended or expected result.

Efficient (adj.): Performing or functioning in the best possible manner with the least waste of time and effort.

Getting my head clear about the difference between these two things has been one of major roadblocks towards finishing my dissertation. I’ve become quite efficient about doing the things I’ve needed to do to get through the last semester but most of what I’ve been doing hasn’t been very effective  in moving me towards finishing.

So, how to break the pattern? It varies from person to person but I started with a  two step plan. First, keep track of what you do during the day. This is something some people do without thinking… I’m not one of those people and a I think I’m a member of the majority in that regard. The result is that I find myself becoming very interrupt-driven. I quickly noticed just how scatter-shot my time had become.

Second, do some “post-mortem” (and “after-death” is the right term here given how my advisor wants to shoot me) and look at how you spend your time after a few days of tracking your work. Then, prune and watch what you do.

Selah.

Posted in why.


The C++11 standard and C++ as a teaching language

The C++ Standards Committee recently published the 2011 update to the language standard with a large body of new features. Looking over some of the changes got me thinking again about my experiences as a software developer using the language and as an instructor teaching others how to use C++. And I’m not certain that the changes in the standard bodes well for the use of C++ as a teaching language.

A Historical Perspective

Like many who were first introduced to computers in the late 1970s and early 1980s, I learned how to hack using BASIC and assembly language, how to program using Pascal, and finally understood computer science when I grokked LISP and Smalltalk in my first run at graduate school. My introduction to C was in the late 1980s while learning to become a UNIX system administrator while working on my Master degree and C++ in my first real job writing point-of-sale software. So,like most people in my generation I’m not a native C++ speaker; most of the time I’m really thinking in C.

So, why comment now?

Part of my Ph.D. experience has involved working as a part-time instructor in our undergraduate program. Our department is very old-school in many ways; one of which is that we use C++ as our primary teaching language. And we teach C++ exactly as I learned the language 20 years ago in that we first teach imperative programming using the language as more fancy version of C and then we teach the object-oriented features. In other words, for the student’s first three or four semester we teach them that “C++ is just a better C compiler” and then dump object orientation on them when they have to also struggle with all of the theory of data structures. This brings us back to some of the features in the new language standard and how people who are taught to program in C++ in this traditional manner will never think to use them.

So what are some of these features?

Danny Kalev is a tech blogger and consultant who served on the C++ standard committee who recently posted a blog (here) that highlighted what he considered to be important new features of the standard. Let’s take a look at a few of those features from a teaching standpoint.

Null pointers

One of the big problems with not only C++ but also C is the way one dealt with concept of null pointers. From day 1 in both languages, the concept has been that machine addresses were represented by an integral subtype with value of 0 indicating an invalid null address. This lead to many issues in programs with people being caviler about treating the integer value of zero as being the same as indicating a NULL pointer. You have to be diligent in teaching people the difference between the two concepts and how to avoid the problems that are introduced by this convention.

So the convention developed that you would define a preprocessor value called “NULL” that you set to zero to indicate you were working with a null pointer value. Eventually this macro was incorporated in the set of headers mandated by the standard. Consider an example from Kalev’s post:

void f(int); //#1
void f(char *);//#2
//C++03
f(0); //which f is called?

In both cases, very dangerous as the compiler can’t figure out which version of the overloaded function to call. Now think how to explain this concept to a neophyte programmer just learning about concepts of machine addresses, pointers, and overloaded functions.

So, the language standard introduces the concept of “nullptr”. For example, the nastiness from Kalev’s example becomes:

void f(int); //#1
void f(char *);//#2
//C++11
f(nullptr) //unambiguous, calls #2

A glorious and wonderful thing for the language and a feature that will help teaching. But a good illustration of the problems that exist in teaching C++ to new programmers.

Delegating constructors

Object orientation is one of most difficult aspects of instructing people in programing C++. The idiosyncrasies of constructors and destructors are bad enough as currently defined but the new standard is adding more complexity to the issue. For instance, the C++11 standard permits the use of delegation in constructors. Again, we consider an example from Kalev’s post:

class M //C++11 delegating constructors
{
 int x, y;
 char *p;
public:
 M(int v) : x(v), y(0),  p(new char [MAX])  {} //#1 target
 M(): M(0) {cout&lt&lt"delegating ctor"}
}

 

At last, we can now safely call other constructors, an excellent idea from an object-theroetical standpoint. However, the entire chain of teaching constructors becomes far more difficult with this feature.

Lambda expressions

The new standard adds the concept of lambda expressions to the language. A lambda expression lets you define functions locally at the place of the call to the function. In C++, this helps reduce some of the security risks that function objects incur in the language. Consider the following example from Kalev’s post:

int main()
{
   char s[]="Hello World!";
   int Uppercase = 0; //modified by the lambda
   for_each(s, s+sizeof(s), [&Uppercase] (char c) {
    if (isupper(c))
     Uppercase++;
    });
 cout&lt&lt"Uppercase&lt&lt" uppercase letters in: "&lt&lts&lt<endl;
}

In this case, we see an example of a lambda expression in the for_each construct where the Uppercase lambda expression defines a C++ expression for switching text to uppercase. Note the general form of the lambda expression

[capture](parameters)-&gtreturn-type   {body}

We see two pedagogical problems from this example: (1) the for_each construct is one that isn’t taught very well when you are inspired by the “C++ as better C” viewpoint of teaching, and (2) more critical, the entire concept of lambda expressions is one that you would not be able to teach until you have developed rather strong fundamental conceptual understanding of language design principles. Thus, not something easily taught to beginning programmers. In most undergraduate computer science programs, it’s a concept not taught until your third or fourth year in the program.

OK, how do we tie all of these thoughts together?

For me, the new standard makes the use of C++ as a teaching language even more problematic. Many of the concepts being added to the language to make it safer and cleaner make it more it more difficult and dangerous to use as a teaching language. Furthermore, it becomes even more problematic if your program is traditional and uses the “C++ as better C compiler” approach to teaching students just starting in their study of computer science.

Closing thought: C++ not a good teaching language

If we begin from the premise of C++ as being less than suited as a teaching language and becoming even more so with the introduction of the revised standard, what then should we use as a teaching language for new programmers? In my recent travels in search of a teaching position, it’s been my observation that many programs have switched to Java and C# as alternatives. These languages suffer from many of the same issues of C++. I’m beginning more and more to believe much as the teaching staff does as CMU and we should be teaching using languages such as Python.

Selah.

References

Danny Kalev: The Biggest Changes in C++11 (and Why You Should Care)

Robert Harper: Teaching FP to Freshmen

Enhanced by Zemanta

Posted in how, why.


A rave on the scholarship of learning

We believe the time has come to move beyond the tired old “teaching versus research” debate and give the familiar and honorable term “scholarship” a broader, more capacious meaning, one that brings legitimacy to the full scope of academic work. Surely, scholarship means engaging in original research. But the work of the scholar also means stepping back from one’s investigation, looking for connections, building bridges between theory and practice, and communicating one’s knowledge effectively to students.
—E. L. Boyer, 1990

A classmate from graduate school was recently hired to teach at a small teaching-oriented institution in the Midwest. Like many newly-minted Ph.Ds, he is now finding that he’s being asked to think more about the metaphysics of teaching rather than worrying about how to teach people how to program. This person asked my opinions on the following “meta-questions” about teaching:

  1. How would you define excellence in teaching?
  2. How would you define the scholarship of teaching?
  3. How do these concepts tie together?

They’re all very open-ended and difficult to answer. Note that the following responses are slanted towards my opinions on the subject and may differ from accepted norms. Standard disclaimers apply; your mileage may vary…

These terms are rather well defined amongst professional educators (by which I mean people who get the “Ed.D” degree from a Department of Education who are experts in the theory of teaching). Look at some of the information that you can find on the website for the “Carnegie Foundation for the Advancement of Teaching” (yes, the same Andrew Carnegie who founded what is now US Steel Corp. and was one of the principal benefactors of Carnegie-Mellon University, go lookup his bio on Wikipedia).

The Carnegie Foundation defines “scholarship in teaching” in three parts:

  1. Scholarship of discovery: research and performance that adds to a knowledge base and the intellectual climate of an institution
  2. Scholarship of integration: drawing together and interpreting diverse kinds of knowledge
  3. Scholarship of application: applying knowledge to practical problems

Working from those definitions, you can define excellence in teaching by measuring, preferably in a quantifiable manner, how well an individual working within a program or a program in an educational institution addresses each of these areas. This is the equivalent of business planning in industry; you must define a set of objectives that you put in place to address these concerns and a set of goals that you must achieve to meet those objectives. Then a set of quantifiable measures are put in place that define whether or not you achieved the goals you have set for yourself.

In a perfect world, an institution’s policies, practices, and infrastructure are aligned with these goals. An institution has to evaluate anything it does against the measures it has put in place for itself and adjust, enhance, eliminate, and/or introduce polices, practices, and structures as required.

These are interesting questions that deserve further thought and ruminations. Look for more posts from me on this subject in the near future.

References:

Posted in why.


It’s gumbo weather

Fall is starting to arrive here in South Louisiana… the temperature is finally dropping into the 70’s during the day and everyone is breaking out the winter clothing. Hey, it’s South Louisiana – you have to be careful to avoid splashing hot oil on your legs when you’re wearing shorts while you’re frying your Thanksgiving turkey.

People down here describe this weather as being “gumbo weather”. So, in that spirit, here’s my favorite gumbo recipe. It’s adapted from one that John Folse included in one of his cookbooks. It’s a bit complicated but mais, cher’, it’s good. If you can’t get good oysters, feel free to use shrimp.

Duck and Sausage Gumbo

Stock
4 (1 ½ pound) mallards or similar ducks
4 ½ qt. water
3 ribs celery, cut into chunks
1 carrot, cut into half
15 peppercorns
4 bay leaves
1 ¼ t. salt
1 t. dried thyme
¼ t. garlic powder
¼ t. red pepper flakes
Gumbo
¾ c. all-purpose flour
¾ c. vegetable oil
2 c. chopped onions
2 c. chopped celery
1 c. chopped green bell pepper
2 carrots, sliced
1 T. chopped garlic
1 lb. andouille or similar smoked sausage, cut into slices
2/3 c. oyster liquor
1/3 c. port
2 bay leaves
½ t. freshly ground black pepper
¼ t. cayenne pepper
2 doz. Oysters
½ c. chopped green onion tops
¼ c. chopped fresh parsley
steamed rice
File’ powder

Stock

Combine the ducks and all other ingredients in a stockpot. Bring to a boil. Reduce the heat and simmer for 3 to 4 hours or until the ducks are tender. Remove the ducks and chop, discarding the skin and bones. Strain the stock into a container discarding the solids. Chill until the fat has congealed on the stock. Remove the fat and reserve for other purposes (Potatoes fried in duck fat, while quite deadly from a coronary aspect, are quite tasty).

Gumbo

Make a roux with the flour and water in a large heavy pot. Add the vegetables and garlic. Cook until vegetables are tender. Add 3 quarts of the duck stock, reserved duck meat, the sausage, oyster liquor, port, bay leaves, black pepper, and cayenne pepper. Bring to a boil. Reduce the heat and simmer for 1 hour. Stir in the oysters, green onion tops, and parsley. Cook for 10 minutes longer. Remove and discard bay leaves. Ladle the gumbo over steamed rice to serve. Sprinkle with file’ powder if desired.

Posted in Uncategorized.


How to setup SSH to not ask for a password?

I’ve had enough people ask me how to do this that I decided to post a summary here on my blog.

Terms:
Client: machine starting the SSH session
Server: machine running the SSH session
On Client:
Use ssh-keygen to generate a new public/private keypair:
ssh-keygen -t dsa
Take the defaults (except for passphrase if you want to be picky)
Now append the generated public key (id_dsa.pub) onto the authorized keys for server:
cat id_dsa.pub | ssh uname@server 'cat >>.ssh/authorized_keys2'

Make certain that .ssh directory is configured with permission 0700 and contents are permission 0600.

Posted in how.


Welcome to my web site!

P2110055

This collection of pages is a reflection of my personal interests and experimentation. I tend to use these things two ways: trying different funky HTML things and as sort of an extended “Bookmark” file. So, pardon the mess and feel free to use this page as jumping off point to lots of neat places

.

Posted in Uncategorized.