Better HN
topnewbestaskshowjobs
Log inSign up

globalrev

349 karma · joined May 4, 2008 (18y ago) · 170 submissions

Submissions

comment 17y ago · link · parent

What about wireless? I have a functioning wireless connection with my Vista desktop. However it seems really hard to get going with Ubuntu. I can't figure out exactly what to do with Ndiswrapper and if I need a new driver. Can't I just use what I have on Linux if I allow proprietary stuff?

Wireless still seems to be the most annoying thing about Linux.

comment 17y ago · link · parent

so his books contained 8000 errors?

comment 17y ago · link · parent

OK one use of this is to check for your copyrighted photos obv.

But will people pay for such a service?

There are just so many companies starting with seemingly no way to make money.

comment 17y ago · link · parent

do you make money?

5.

Ask HN: So do these companies make actual money or they just have revenue?

8 points · by globalrev · 17y ago · 3 comments

comment 17y ago · link · parent

Doesn't Skype make money(as in profit not just revenue)?

comment 17y ago · link · parent

This has been up so many times. It's not happening, live with it. Python "lambdas" can do most things you need anyway.Normally I don't really find the need for supercomplicated lambdas and you can do if-else in lambda s in Python with the ternary operator, see below:

####### def throwaway_function(emp): if emp.salary > developer.salary: return fireEmployee(emp) else: return extendContract(emp)

employees.select(throwaway_function) ######

Python lambda: filter(lambda emp: fireEmployee(emp) if emp.salary > developer.salary else extendContract(emp), employees)

Don't know what select does but it sounds like filter. So if that works as intended(is the ruby version both returning value and side-effecting?) or not I'm not sure but you probably could make it.

comment 17y ago · link · parent

Could someone give a very simple example of a problem to solve with this?

comment 17y ago · link · parent

OK but then how is this "working"? I mean it is very cool and it might work if someone puts effort into it. But is there any reasonable way of using this right now?

comment 17y ago · link · parent

does GA and GP behave somewhat predictable then? Couldn't it, if you are unlucky, take a very long time to converge?

comment 17y ago · link · parent

It is not that hard to build yourself.

comment 17y ago · link · parent

They seem to say generally that they don't make much money but obviously that doesn't mean that they don't.

comment 17y ago · link · parent

Does R have a Java binding?

comment 17y ago · link · parent

Is the pirate bay making money?

comment 17y ago · link · parent

it doesn't load for me, just a blank screen, what do I need to do?

comment 17y ago · link · parent

how is Mathematica compared to Matlab? As I understand Mathematica is for all kinds of math while Matlab is basically only matrix and linear algebra-stuff(with a lot of libraries for applications of that).

Is Mathematica as good as Matlab for linear algebra?

comment 17y ago · link · parent

I didn't catch how, could you explain?

comment 17y ago · link · parent

All I know is is that Git i supereasy to use for a beginner for 1-man-projects if you get the right help or tutorial. Preferrably start a repo at github and you will be waled through how to create a repo(not that there is much to it).

git init git add . git commit -m "blah" git push origin master

git branch name git checkout

easy-peasy

comment 17y ago · link · parent

Did I miss something? There are 2 parts, one which is pro microsoft and then a defense post which is pro Linux...right?

comment 17y ago · link · parent

I just did this because I got inspired. What does it count as, genetic programming? It uses naive mutation and crossover(don't know if they qualfiy as real crossover and mutation) and a simple fitness function. It is fairly pointless since all it does is find a list with ones but it does so in just around 400 generations while random guessing takes forever.

  from __future__ import division
  import matplotlib.mlab as M
  import matplotlib.pyplot as plt
  import random as R
  
  def crossover(a, b):
      new = []
      for x,y in zip(a,b):
          if R.random() > 0.5:
              new.append(x)
          else:
              new.append(y)
      return new

  def mutate(xs):
      xs[int(R.uniform(0, len(xs)))] = int(R.uniform(1, 10))
      return xs

  def fitness(xs, goal):
      summa = 0
      for x,y in zip(xs, goal):
          summa += abs(x-y)
      return summa, xs, True if summa == 0 else False

  def nFittest(xs, goal, n=2):
      fittest = sorted(fitness(x, goal) for x in xs)[:n]
      if fittest[0][2] :
          return fittest[0]
      elif fittest[1][2]:
          return fittest[1]
      else:
          return fittest

  def init(fields, n):
      return [[int(R.uniform(1,10)) for x in     xrange(fields)] for y in xrange(n)]

  def newGen(a,b,n):
      next = [crossover(a,b) for x in xrange(n)]
      mutated = []
      for x in next:
          if R.random() > 0.9: mutated.append(mutate(x))
          else: mutated.append(x)
      return mutated

  def run(printing=True):
      n = 0
      first = init(15, 10)
      while n < 1000000:
          n += 1
          next = nFittest(first,   [1,1,1,1,1,1,1,1,1,1,1,1,1,1,1], 2)
          if type(next) == tuple: break
          first = newGen(next[0][1],next[1][1], 10)
      if printing:
          print "Nbr of generations: ", n
          print next
      return n, next

  def plot():
      trials = [run(False)[0] for x in range(100)]
      print "Done trials"
       averages = [sum(trials[:x]) / len(trials[:x])\
                  for x in xrange(1,len(trials)+1)]
      print "Done averages"
      plt.plot([x for x in xrange(len(averages))],   averages, 'ro')
      plt.axis([1, 100, 0, 1000])
      plt.show()

  def test():
      goal = [1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]
      c=0
      while 1:
          c += 1
          x = [int(R.uniform(1,10)) for y in range(15)]
          if sum(x) == 15: break
          if c % 10000 == 0: print c
      print x

comment 17y ago · link · parent

"I don't think so, not beyond your very first couple of jobs." And how long is that, 5-10years?

And for the really attractive jobs, do you even get a shot if straight out of college if you are not from a top one(often you don't either how because of no experience but when you do)?

Don't want to bash the point though. Effort > talent, I agree.

comment 17y ago · link · parent

Sure but what I mean is for engineering the difference between a good and bad college might be bigger than say for economy?

comment 17y ago · link · parent

Not an expert on the area at all but it seems perhaps the college you go to is more important for technical professions than business ones?

comment 17y ago · link · parent

Does anyone else think so? I'm using Clojure a lot and really like it.

But Lisp has been around for 50 years and never hit the mainstream so it seems there perhaps is something about it that doesn't fit with most programmers?

Also it only offers one form of concurrnecy and while I like it there is still much speculation and research in the area. Scala for example kind of builds on the whole Java-language and offers a more recognizable language for Java-developers and more opportunities to roll your own concurrency-mechanisms, or at least that's the impression I've gotten.

And then we have Haskell and Erlang.

comment 17y ago · link · parent

I beat it with The good in the good the bad and the ugly. He answered Leon.

It is timing out all the time, unberable.

comment 18y ago · link · parent

Not to be a know-it-all and I-told-you-so but how could they not see the problem with this model?

comment 18y ago · link · parent

Could anyone point me on how to solve this(either a solution or preferrably a pointer on how to get to it): "Q: Given a function which produces a random integer in the range 1 to 5, write a function which produces a random integer in the range 1 to 7."

First I thought it was simple but the I got stuck, maybe I'm just tired. No matter how I twsit and turn it I seem to get only an even distribution over 5 numbers.

123456