Google "programming language" and look at the #1 rank ;)

  • Thread starter Mehr, Assaph (Assaph)
  • Start date
M

Mehr, Assaph (Assaph)

P

Phil Tomson

Just a few links to make you happy - look at the #1 link for each:

Googling "Programming":
http://www.google.com/search?sourceid=mozclient&ie=utf-8&oe=utf-8&q=prog
ramming

I get a link to "Programming in C" first and second is "Python
Programming Language"

I get "Pythong Programming Language" as #1, "Java Technology" #2 and
"Ruby Home Page" #3.


"Ruby Home Page" shows up as the first link for this query ;-)


Did Ruby show up first in all cases for you?

Phil
 
S

Sascha Ebach

Hi,
Just a few links to make you happy - look at the #1 link for each:

Googling "Programming":
http://www.google.com/search?sourceid=mozclient&ie=utf-8&oe=utf-8&q=prog
ramming

Googling "Programming Language":
http://www.google.com/search?hl=en&lr=&ie=UTF-8&q=programming+language&b
tnG=Search

Googling "Best Programming Language":
http://www.google.com/search?hl=en&lr=&ie=UTF-8&q=best+programming+langu
age&btnG=Search

That is nice. Now, to cement this, we should all put a link on our web site:

<a href="http://www.ruby-lang.org">Best programming language</a>
 
D

David Ross

--- Sascha Ebach said:
That is nice. Now, to cement this, we should all put
a link on our web site:

<a href="http://www.ruby-lang.org">Best programming
language</a>

Each time I recommend Ruby to another programmer, and
point them to a few web pages they see things like
that. Then they tell me the Ruby programmers and I are
full of ourselves. I really wouldn't want to put that
on a website :) Even though Ruby *is* the best
programming language. /me runs from the angry Python
mob.

----------------------------------------
-- Name: David Ross
-- Phone: 865.539.3798
-- Email: drossruby [at] yahoo [dot] com
----------------------------------------



__________________________________
Do you Yahoo!?
Take Yahoo! Mail with you! Get it on your mobile phone.
http://mobile.yahoo.com/maildemo
 
A

Alexander Kellett

Each time I recommend Ruby to another programmer, and
point them to a few web pages they see things like
that. Then they tell me the Ruby programmers and I are
full of ourselves. I really wouldn't want to put that
on a website :) Even though Ruby *is* the best
programming language. /me runs from the angry Python
mob.

They are just jealous.
They've never before been *proud* of the language they use.
Programming in Ruby, its like living in a country that one
can feel patriotic for. Still I didn't find such a country.
Frankly, I doubt such a country could exist for me.
On the other hand.. Ruby does.

I'm so very glad that Ruby fills in for this lost land.

:)

Alex
 
D

David Morton

David said:
that. Then they tell me the Ruby programmers and I are
full of ourselves. I really wouldn't want to put that
Reminds me of a good quote:

"I'm not closed minded, they're just WRONG!"

:p
 
D

David Ross

--- David Morton said:
that
Reminds me of a good quote:

"I'm not closed minded, they're just WRONG!"

:p

Well you have to pity them becuase they are usually
people who know only *that* language. It is really sad


8]

I try to sway them with kind words, and ask them they
try Ruby. If that doesn't work. I use the

"Programming in Ruby will get you Japanese chicks and
cuties" line. :)

Japanese or Nippon, whichever I feel at the time.

Gets them everytime (*when they are male anyway)

-----------------------------------------
-- Name: David Ross
-- Phone: 865.539.3798
-- Email: drossruby [at] yahoo [dot] com
-----------------------------------------




__________________________________
Do you Yahoo!?
New and Improved Yahoo! Mail - 100MB free storage!
http://promotions.yahoo.com/new_mail
 
D

Dave Burt

Methinks Rubyists tend to be less rabid than those LISPers... (what's (with
(all (those (brackets (anyhow? (and (where's (the (syntax?))))))))))

David Ross said:
Each time I recommend Ruby to another programmer, and
point them to a few web pages they see things like
that. Then they tell me the Ruby programmers and I are
full of ourselves. I really wouldn't want to put that
on a website :) Even though Ruby *is* the best
programming language. /me runs from the angry Python
mob.

 
B

Bill Clagett

As a user of both Ruby and Lisp, I assure you that are a noisy few
among the adherents of both languages. Lisp evangelists generally
sound different than Ruby evangelists. But I'd be hard pressed decide
which are more "rabid".

bill
 
B

Brian Wisti

Hey now, that's not quite fair. Amusing, but not quite
fair. I'm pretty fond of Lisp-ish languages these
days. It's a nice break from the syntax overload of a
lot of other languages :)

-- Brian Wisti

--- Dave Burt said:
Methinks Rubyists tend to be less rabid than those
LISPers... (what's (with
(all (those (brackets (anyhow? (and (where's (the
(syntax?))))))))))




programming language</a>




__________________________________
Do you Yahoo!?
New and Improved Yahoo! Mail - Send 10MB messages!
http://promotions.yahoo.com/new_mail
 
N

Nicholas Van Weerdenburg

Hi all,

Are there any libraries that handle YAML->XML conversion? I want to use
in-line YAML to allow command-line insertion of XML fragments into a
document.

e.g. addxml.rb --entry "config : {name : url, value : www.blah.com }"

would enter:
<config>
<name>url</name>
<value>www.blah.com</value>
</config>

Not a hard problem, but I wasn wondering if I was missing any useful
standard methods that I overlooked.

Thanks.
Nick
 
Z

Zach Dennis

I am having problems returning a value from a proc object:

@@mappings.each{ |hsh|
begin
if( hsh['type'] == c['type'] ) then
eval( "comp=#{hsh['template']}" )
hsh.each_key{ |key|
m = proc { @@ignore.each{ |i| return true if( key == i ) }
}.call
puts m;
}
has_mapping = true;
end
rescue; raise "Unable to evaluate passed in expression:
#{hsh['template']}"; end
break if( has_mapping ); }

It is at the line: m = proc { @@ignore.each{ |i| return true if( key
== i ) } }.call
that I am having the problem. I want "m" to be true, but instead it
leaves the calling function.

I have modified the line to be:

m = nil;
proc { @@ignore.each{ |i| m=true if( key == i ) } }.call

but I was just wondering if I could return a value w/o having to leave
the outer function.

Zach
 
J

Joel VanderWerf

Zach said:
I am having problems returning a value from a proc object:

@@mappings.each{ |hsh|
begin
if( hsh['type'] == c['type'] ) then
eval( "comp=#{hsh['template']}" )
hsh.each_key{ |key|
m = proc { @@ignore.each{ |i| return true if( key == i ) }
}.call
puts m;
}
has_mapping = true;
end
rescue; raise "Unable to evaluate passed in expression:
#{hsh['template']}"; end
break if( has_mapping ); }

It is at the line: m = proc { @@ignore.each{ |i| return true if( key
== i ) } }.call
that I am having the problem. I want "m" to be true, but instead it
leaves the calling function.

I have modified the line to be:

m = nil;
proc { @@ignore.each{ |i| m=true if( key == i ) } }.call

but I was just wondering if I could return a value w/o having to leave
the outer function.

Use break:

def fn
m = proc {break 3}.call
"m = #{m}"
end

p fn # ==> "m = 3"
 
N

NAKAMURA, Hiroshi

Hi,

Are there any libraries that handle YAML->XML conversion? I want to use
in-line YAML to allow command-line insertion of XML fragments into a
document.

e.g. addxml.rb --entry "config : {name : url, value : www.blah.com }"

would enter:
<config>
<name>url</name>
<value>www.blah.com</value>
</config>

Just a proof-of-concept thing (not insertion but dumping.)

% cat xmlgenerator.rb
require 'soap/marshal'

class XMLGenerator < SOAP::SOAPGenerator
def obj_to_xml(obj)
soap = SOAP::Mapping.obj2soap(obj)
soap.elename = XSD::QName.new(nil, soap.type.name)
convert_to_xml(soap)
end

def hash_to_xml(hash, name)
soap = SOAP::SOAPElement.from_obj(hash)
soap.elename = XSD::QName.new(nil, name)
convert_to_xml(soap)
end

private

def convert_to_xml(soap)
@generate_explicit_type = false
ns = XSD::NS.new
@buf = ''
@indent = ''
encode_data(ns, true, soap, nil)
@buf
end
end

generator = XMLGenerator.new

class Config
def initialize(name, value)
@name = name
@value = value
end
end

obj1 = Config.new("url", "www.blah.com")
puts generator.obj_to_xml(obj1)

require 'yaml'
obj2 = YAML.load("config : {name : url, value : www.blah.com }")
puts generator.hash_to_xml(obj2, 'root')

% ruby xmlgenerator.rb

<Config>
<name>url</name>
<value>www.blah.com</value>
</Config>

<root>
<config>
<name>url</name>
<value>www.blah.com</value>
</config>
</root>

Regards,
// NaHi
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top