Ruby China
  • Topics
  • 招聘
  • Wiki
  • 酷站
  • Gems
  • Sign Up
  • Sign In
@blacktulip
VIP
NO. 207 / 2011-11-23

117 Topics / 2599 Replies
40 Followers
0 Following
4 Favorites
GitHub Public Repos
  • octopress-theme-yinyang 37

    YinYang (陰陽) is a minimal, responsive theme for Octopress.

  • vimfiles 1

    My vimfiles

  • qingwang.github.com 0

More on GitHub
  • Overview
  • Topics
  • Replies
  • Favorites
  • Following
  • Followers
  • 求科普数据库外键及常用字段的建表方法,遇到一个问题,详见帖子内容 at April 28, 2014

    你这网站突然放那么大声的音乐,简直是扯淡!吓死人了,立刻关掉再也不会去了。这种扯淡的用户体验还好玩?

    吓尿了我艹。

  • 求科普数据库外键及常用字段的建表方法,遇到一个问题,详见帖子内容 at April 28, 2014

    index 下就好了吧,提前优化是万恶之源....

  • 我是 RubyConf China 的组织者,介绍下第六届的进展还有一些个人想法 at April 28, 2014

    #39 楼 @chunlea thanks

  • 我是 RubyConf China 的组织者,介绍下第六届的进展还有一些个人想法 at April 28, 2014

    #17 楼 @chunlea 对了请问一下 rubymotion 是怎么实现 storyboard 的?

  • 我是 RubyConf China 的组织者,介绍下第六届的进展还有一些个人想法 at April 28, 2014

    啥时候在深圳办一届啊

  • RailsConf 2014 DHH 做的开幕主题演讲视频 at April 28, 2014

    #18 楼 @rockliu 藐视权威?他自己才是权威吧

  • 又一坑技术人的 at April 26, 2014

    #8 楼 @xiaoronglv 股份也好不到哪里去,现金为王

  • 又一坑技术人的 at April 26, 2014

    再次证明期权都是耍流氓

  • 部署 discourse 遇到的问题 at April 26, 2014

    Warning: This Guide is Deprecated

    这么大的标题字体楼主应该有看到才是

  • 做题:Custom Enumerators - Fibonacci at April 25, 2014
    fib = Enumerator.new do |y|
      i, j = 1, 1
      loop do
        y.yield i
        i, j = j, i + j
      end
    end
    
  • 做题:Bag#every? at April 25, 2014

    反正已经出过一次洋相了不介意再出一次...

    def every?
      self.each do |item|
        if block_given?
          return false unless yield item
        else
          return false unless item
        end
      end
      true
    end
    
  • 一起来做题: Get config values of hash at April 25, 2014

    #18 楼 @chenge 一旦想明白原理就会发现可读性其实很好... 比任何一楼的解答可读性都好

  • 一起来做题: Get config values of hash at April 25, 2014

    #15 楼 @zgm 有... 当 *args 为空时返回的不是 default 而是整个 hash

  • 一起来做题: Get config values of hash at April 25, 2014

    #13 楼 @zgm 噢... 看懂了,没想到可以拼字符串啊,还是你牛。

  • 一起来做题: Get config values of hash at April 25, 2014

    #11 楼 @zgm 看不懂... 求详解

  • 一起来做题: Get config values of hash at April 25, 2014

    #7 楼 @zgm 给了 default 就不抛异常了

    fetch(key [, default] ) → obj
    fetch(key) {| key | block } → obj
    
    Returns a value from the hash for the given key. If the key can’t be found, there are several options: With no other arguments, it will raise an KeyError exception; if default is given, then that will be returned; if the optional code block is specified, then that will be run and its result returned.
    
  • 一起来做题: Get config values of hash at April 25, 2014

    #5 楼 @saiga 好厉害,不过这个也没检查剩余 keys

  • 一起来做题: Get config values of hash at April 25, 2014

    #2 楼 @Kabie 额,说的是,反正楼主的 test 是 pass 了... 修改了一下检查剩余 keys。

  • 一起来做题: Get config values of hash at April 25, 2014

    我就贴个 java 风格的 ruby 代码让大家来耻笑吧,坐等楼下的一行流。

    class Hash
      def get_value(default, *keys)
    
        hash_copy = self.clone
    
        if hash_copy.has_key?(keys[0])
          hash_copy = hash_copy[keys[0]]
    
          if hash_copy.is_a?(Hash)
            keys.shift
            hash_copy.get_value(default, *keys)
          elsif keys.size == 1
            hash_copy
          else
            default
          end
    
        else
          default
        end
    
      end
    end
    
  • haml slim 之流真的好吗? at April 24, 2014

    erb 党撸过点赞

  • 为什么 Ruby China 论坛上一直让大家不让用 Windows 开发? at April 24, 2014

    你自己贴的两年前那个帖子说得不够详细么?

  • 有哪些免费的 VPS 不错的? at April 24, 2014

    无

  • 感觉达到人生巅峰了! at April 24, 2014

    啥也看不到

  • 一道 Ruby 题目 at April 23, 2014

    果然都是一行流

  • Prev
  • 1
  • 2
  • …
  • 24
  • 25
  • 26
  • 27
  • 28
  • …
  • 83
  • 84
  • Next
关于 / RubyConf / Ruby 镜像 / RubyGems 镜像 / 活跃会员 / 组织 / API / 贡献者
由众多爱好者共同维护的 Ruby 中文社区,本站使用 Homeland 构建,并采用 Docker 部署。
服务器由 赞助 CDN 由 赞助
iOS 客户端 / Android 客户端 简体中文 / English