ruby tag

542 questions


1 answers
28 views
0
She's studying Ruby's language. Can I ask you a quick question about I/O?

print(Enter purchase value:)purchase=gets.chomp()print (Enter Sales Value:)sell=gets.chomp()puts(sell-purchase)That's the code When I said 400 and 500, The result I want is 900 It's 400500 I think it'...

2 years ago

1 answers
45 views
0
Problems with the version of ruby and rails on Amazon Linux AMI (?)

I am a student studying ruby and rails using Amazon Linux AMI.By default, the AMI has Ruby 2.0.0 installed. So I reinstalled it with the latest version.(ruby is 2.3.1 and rails is 5.0.0.1) But somehow...

2 years ago

1 answers
82 views
0
Ruby crawling specific url only.

I'm practicing web crawling using nokogiri.http://news.naver.com/main/read.nhn?mode=LSD&mid=shm&sid1=103&oid=001&aid=0008639625I want to pick the title of Naver News, but if I run the ...

2 years ago

1 answers
48 views
0
Ruby on rails server on/off question

From ruby-on-railsThe command to server on is rails -b $IP -p $PORTWhat's the point of turning it off?Even if you do ctrl+c, only c is entered and the server does not die c only

2 years ago

1 answers
47 views
0
Canot load soch file -- bcrypt workaround in Ruby On Rails

LoadError in UsersController#createcannot load such file -- bcryptExtracted source (around line #2):class User < ApplicationRecord has_secure_passwordendWhat kind of error is this?Right now,

2 years ago

2 answers
28 views
0
Ruby, let me ask you a conditional question.

Let me get to the point briefly.When writing if statements in PythonFor example, The conditional statement if x in s is if x in sI don't know how to express this in ruby.I don't think Ruby supports ex...

2 years ago

1 answers
99 views
0
Jekyll: It doesn't regenerate when you turn it on the docker.

Hello.Refer to the following locally for ruby-based jekyll. jekyll serveWhen turning on the docker, the command was done as follows using the absolute path.docker run --name blog -v C:/dev/record/blog...

2 years ago

1 answers
31 views
0
Rails external access is not possible.

I'm studying Ruby on Rails.Ruby is using version 2.3.7 and Rails is using version 5.2.After some development, I want to distribute it to AWS to allow external access, but even if I run the rails -b 0....

2 years ago

1 answers
28 views
0
Extracting numbers from text with Ruby

Is there a short way to extract a number like 1 or 10 from a string like Level 1 or Level 10? I think Ruby made something besides using regular expressions.

2 years ago

1 answers
41 views
0
What is the exact role of eval in Ruby? And I heard it's not good to use it. Is that true?

There is a problem that I want to use eval while working on Rails. It was when I received JSON input and saved it in DB. I received the JSON Array and saved it in DB, so it's a string [1, 2, 3] is sav...

2 years ago
« - 50 - »

© 2024 OneMinuteCode. All rights reserved.