The document discusses some of the stereotypes and misconceptions about the Ruby programming language, as well as demonstrating some of Ruby's features through examples in IRB (Interactive Ruby). It notes that while Ruby is often considered easy to use and elegant, it also has some quirks or unexpected behaviors that can surprise newcomers. The document aims to illustrate both the benefits of Ruby as well as some of its less intuitive aspects.
PHP 7 – What changed internally? (PHP Barcelona 2015)Nikita Popov
One of the main selling points of PHP 7 is greatly improved performance, with many real-world applications now running twice as fast… But where do these improvements come from? At the core of PHP 7 lies an engine rewrite with focus on improving memory usage and performance. This talk provides an overview of the most significant changes, briefly covering everything from data structure changes, over enhancements in the executor, to the new compiler implementation.
PHP 7 – What changed internally? (Forum PHP 2015)Nikita Popov
One of the main selling points of PHP 7 is greatly improved performance, with many real-world applications now running twice as fast… But where do these improvements come from?
At the core of PHP 7 lies an engine rewrite with focus on improving memory usage and performance. This talk provides an overview of the most significant changes, briefly covering everything from data structure changes, over enhancements in the executor, to the new compiler implementation.
As a result of an engine rewrite with focus on more efficient data structures, PHP 7 offers much improved performance and memory usage. This session describes important aspects of the new implementation and how it compares to PHP 5. A particular focus will be on the representation of values, arrays and objects.
PHP 7 – What changed internally? (PHP Barcelona 2015)Nikita Popov
One of the main selling points of PHP 7 is greatly improved performance, with many real-world applications now running twice as fast… But where do these improvements come from? At the core of PHP 7 lies an engine rewrite with focus on improving memory usage and performance. This talk provides an overview of the most significant changes, briefly covering everything from data structure changes, over enhancements in the executor, to the new compiler implementation.
PHP 7 – What changed internally? (Forum PHP 2015)Nikita Popov
One of the main selling points of PHP 7 is greatly improved performance, with many real-world applications now running twice as fast… But where do these improvements come from?
At the core of PHP 7 lies an engine rewrite with focus on improving memory usage and performance. This talk provides an overview of the most significant changes, briefly covering everything from data structure changes, over enhancements in the executor, to the new compiler implementation.
As a result of an engine rewrite with focus on more efficient data structures, PHP 7 offers much improved performance and memory usage. This session describes important aspects of the new implementation and how it compares to PHP 5. A particular focus will be on the representation of values, arrays and objects.
The journey of an (un)orthodox optimizationSian Lerk Lau
We live in a world that celebrates diversity. When it comes to code and database, we don’t. However, reality hits when we are working on an existing code base which it served its purpose, time-tested, just work™, but just one tiny little problem… it’s slow. What can we do?
Model relationships in our application often a reflection of the needs of our business requirements. However these requirements change over time and the relationships can be a hell lot difficult to normalize. Putting aside a potential time consuming and bug-friendly code refactoring, migration on a big database will incur long downtime and perhaps significant hair lost, if not money.
The above scenario perhaps ring a bell on your current workplace. As the data grows larger each day, scalability issues surfaced and long response time haunt us, if not our client. Perhaps we can no longer sweep it under the carpet.
In this talk, I would like to share my journey in optimizing a service task from 10 minutes to 30 seconds.
The breakdown as follow: 1. Database optimisation 2. Python code optimisation 3. Recommendation on optimisation best practices
Python's "batteries included" philosophy means that it comes with an astonishing amount of great stuff. On top of that, there's a vibrant world of third-party libraries that help make Python even more wonderful. We'll go on a breezy, example-filled tour through some of my favorites, from treasures in the standard library to great third-party packages that I don't think I could live without, and we'll touch on some of the fuzzier aspects of the Python culture that make it such a joy to be part of.
Version 5.0 will include version 2.0 of the Zend Engine
New object model is more powerful and intuitive
Objects will no longer be passed by value; they now will be passed by reference
Increases performance and makes OOP more attractive
SADI in Perl - Protege Plugin Tutorial (fixed Aug 24, 2011)Mark Wilkinson
IMPORTANT CORRECTION TO THIS SLIDESHOW WAS MADE August 24, 2011. How to use the Protege SADI plugin to generate SADI-compliant semantic web services. Created for the 2011 DBCLS BioHackathon. Credits to Mark Wilkinson, Benjamin Vandervalk, Luke McCarthy, Edward Kawas.
Banishing Loops with Functional Programming in PHPDavid Hayes
From a talk I've given a few time sat programming conferences about making your code better with functional programming principles. The example code is all PHP
PuppetConf 2017: Hiera 5: The Full Data Enchilada- Hendrik Lindberg, PuppetPuppet
Separating data from code is just as important as it has always been for creating reusable code that can be conveniently configured for different situations. This has been possible to do in Puppet for quite some time, using Hiera and automatic parameter lookup. The new release of Hiera 5, introduced late in the Puppet 4.x series, brings new capabilities for data management. Data is no longer just global — it can be defined in an environment and inside a module. Plus, data integration no longer requires special backends — the point of integration is now a function. There are also new ways to reference data files. And there's so much more in Hiera 5. This talk introduces all the features of Hiera 5 now available in Puppet 5, and shows how they can be used. Integrators who want to write their own backends will also learn how to do that.
(This is presentation slide for RubyKaigi 2009)
Erubis is very fast and extensible implementation of eRuby. In this slides, I show you features of Erubis, and issues related to eRuby and solution by Erubis. Also I show you some ideas about the future of template system.
The journey of an (un)orthodox optimizationSian Lerk Lau
We live in a world that celebrates diversity. When it comes to code and database, we don’t. However, reality hits when we are working on an existing code base which it served its purpose, time-tested, just work™, but just one tiny little problem… it’s slow. What can we do?
Model relationships in our application often a reflection of the needs of our business requirements. However these requirements change over time and the relationships can be a hell lot difficult to normalize. Putting aside a potential time consuming and bug-friendly code refactoring, migration on a big database will incur long downtime and perhaps significant hair lost, if not money.
The above scenario perhaps ring a bell on your current workplace. As the data grows larger each day, scalability issues surfaced and long response time haunt us, if not our client. Perhaps we can no longer sweep it under the carpet.
In this talk, I would like to share my journey in optimizing a service task from 10 minutes to 30 seconds.
The breakdown as follow: 1. Database optimisation 2. Python code optimisation 3. Recommendation on optimisation best practices
Python's "batteries included" philosophy means that it comes with an astonishing amount of great stuff. On top of that, there's a vibrant world of third-party libraries that help make Python even more wonderful. We'll go on a breezy, example-filled tour through some of my favorites, from treasures in the standard library to great third-party packages that I don't think I could live without, and we'll touch on some of the fuzzier aspects of the Python culture that make it such a joy to be part of.
Version 5.0 will include version 2.0 of the Zend Engine
New object model is more powerful and intuitive
Objects will no longer be passed by value; they now will be passed by reference
Increases performance and makes OOP more attractive
SADI in Perl - Protege Plugin Tutorial (fixed Aug 24, 2011)Mark Wilkinson
IMPORTANT CORRECTION TO THIS SLIDESHOW WAS MADE August 24, 2011. How to use the Protege SADI plugin to generate SADI-compliant semantic web services. Created for the 2011 DBCLS BioHackathon. Credits to Mark Wilkinson, Benjamin Vandervalk, Luke McCarthy, Edward Kawas.
Banishing Loops with Functional Programming in PHPDavid Hayes
From a talk I've given a few time sat programming conferences about making your code better with functional programming principles. The example code is all PHP
PuppetConf 2017: Hiera 5: The Full Data Enchilada- Hendrik Lindberg, PuppetPuppet
Separating data from code is just as important as it has always been for creating reusable code that can be conveniently configured for different situations. This has been possible to do in Puppet for quite some time, using Hiera and automatic parameter lookup. The new release of Hiera 5, introduced late in the Puppet 4.x series, brings new capabilities for data management. Data is no longer just global — it can be defined in an environment and inside a module. Plus, data integration no longer requires special backends — the point of integration is now a function. There are also new ways to reference data files. And there's so much more in Hiera 5. This talk introduces all the features of Hiera 5 now available in Puppet 5, and shows how they can be used. Integrators who want to write their own backends will also learn how to do that.
(This is presentation slide for RubyKaigi 2009)
Erubis is very fast and extensible implementation of eRuby. In this slides, I show you features of Erubis, and issues related to eRuby and solution by Erubis. Also I show you some ideas about the future of template system.
Pls enjoy this presentation. This is all about my marmot's life and history. He looks cute and fluffy (as in the photo) and his name is called Meat Bun. He is a Vancouver sidekick marmot with no IQ and looked stupid
Slides containing information about my favorite features of the Ruby language. Many of these features exist in other languages, but in the context of my experience as a C, C++, and Java developer, offer a dramatic increase in expressiveness and productivity.
This slide show can also be used to teach a Ruby overview.
Presented on 8/14/2012 at BostonRb. This talk provides a nice intro and overview of what RubyMotion is and whether or not it's worth incorporating into your development toolkit.
Courier management system project report.pdfKamal Acharya
It is now-a-days very important for the people to send or receive articles like imported furniture, electronic items, gifts, business goods and the like. People depend vastly on different transport systems which mostly use the manual way of receiving and delivering the articles. There is no way to track the articles till they are received and there is no way to let the customer know what happened in transit, once he booked some articles. In such a situation, we need a system which completely computerizes the cargo activities including time to time tracking of the articles sent. This need is fulfilled by Courier Management System software which is online software for the cargo management people that enables them to receive the goods from a source and send them to a required destination and track their status from time to time.
Quality defects in TMT Bars, Possible causes and Potential Solutions.PrashantGoswami42
Maintaining high-quality standards in the production of TMT bars is crucial for ensuring structural integrity in construction. Addressing common defects through careful monitoring, standardized processes, and advanced technology can significantly improve the quality of TMT bars. Continuous training and adherence to quality control measures will also play a pivotal role in minimizing these defects.
Overview of the fundamental roles in Hydropower generation and the components involved in wider Electrical Engineering.
This paper presents the design and construction of hydroelectric dams from the hydrologist’s survey of the valley before construction, all aspects and involved disciplines, fluid dynamics, structural engineering, generation and mains frequency regulation to the very transmission of power through the network in the United Kingdom.
Author: Robbie Edward Sayers
Collaborators and co editors: Charlie Sims and Connor Healey.
(C) 2024 Robbie E. Sayers
Immunizing Image Classifiers Against Localized Adversary Attacksgerogepatton
This paper addresses the vulnerability of deep learning models, particularly convolutional neural networks
(CNN)s, to adversarial attacks and presents a proactive training technique designed to counter them. We
introduce a novel volumization algorithm, which transforms 2D images into 3D volumetric representations.
When combined with 3D convolution and deep curriculum learning optimization (CLO), itsignificantly improves
the immunity of models against localized universal attacks by up to 40%. We evaluate our proposed approach
using contemporary CNN architectures and the modified Canadian Institute for Advanced Research (CIFAR-10
and CIFAR-100) and ImageNet Large Scale Visual Recognition Challenge (ILSVRC12) datasets, showcasing
accuracy improvements over previous techniques. The results indicate that the combination of the volumetric
input and curriculum learning holds significant promise for mitigating adversarial attacks without necessitating
adversary training.
Vaccine management system project report documentation..pdfKamal Acharya
The Division of Vaccine and Immunization is facing increasing difficulty monitoring vaccines and other commodities distribution once they have been distributed from the national stores. With the introduction of new vaccines, more challenges have been anticipated with this additions posing serious threat to the already over strained vaccine supply chain system in Kenya.
Cosmetic shop management system project report.pdfKamal Acharya
Buying new cosmetic products is difficult. It can even be scary for those who have sensitive skin and are prone to skin trouble. The information needed to alleviate this problem is on the back of each product, but it's thought to interpret those ingredient lists unless you have a background in chemistry.
Instead of buying and hoping for the best, we can use data science to help us predict which products may be good fits for us. It includes various function programs to do the above mentioned tasks.
Data file handling has been effectively used in the program.
The automated cosmetic shop management system should deal with the automation of general workflow and administration process of the shop. The main processes of the system focus on customer's request where the system is able to search the most appropriate products and deliver it to the customers. It should help the employees to quickly identify the list of cosmetic product that have reached the minimum quantity and also keep a track of expired date for each cosmetic product. It should help the employees to find the rack number in which the product is placed.It is also Faster and more efficient way.
Event Management System Vb Net Project Report.pdfKamal Acharya
In present era, the scopes of information technology growing with a very fast .We do not see any are untouched from this industry. The scope of information technology has become wider includes: Business and industry. Household Business, Communication, Education, Entertainment, Science, Medicine, Engineering, Distance Learning, Weather Forecasting. Carrier Searching and so on.
My project named “Event Management System” is software that store and maintained all events coordinated in college. It also helpful to print related reports. My project will help to record the events coordinated by faculties with their Name, Event subject, date & details in an efficient & effective ways.
In my system we have to make a system by which a user can record all events coordinated by a particular faculty. In our proposed system some more featured are added which differs it from the existing system such as security.
Forklift Classes Overview by Intella PartsIntella Parts
Discover the different forklift classes and their specific applications. Learn how to choose the right forklift for your needs to ensure safety, efficiency, and compliance in your operations.
For more technical information, visit our website https://intellaparts.com
Automobile Management System Project Report.pdfKamal Acharya
The proposed project is developed to manage the automobile in the automobile dealer company. The main module in this project is login, automobile management, customer management, sales, complaints and reports. The first module is the login. The automobile showroom owner should login to the project for usage. The username and password are verified and if it is correct, next form opens. If the username and password are not correct, it shows the error message.
When a customer search for a automobile, if the automobile is available, they will be taken to a page that shows the details of the automobile including automobile name, automobile ID, quantity, price etc. “Automobile Management System” is useful for maintaining automobiles, customers effectively and hence helps for establishing good relation between customer and automobile organization. It contains various customized modules for effectively maintaining automobiles and stock information accurately and safely.
When the automobile is sold to the customer, stock will be reduced automatically. When a new purchase is made, stock will be increased automatically. While selecting automobiles for sale, the proposed software will automatically check for total number of available stock of that particular item, if the total stock of that particular item is less than 5, software will notify the user to purchase the particular item.
Also when the user tries to sale items which are not in stock, the system will prompt the user that the stock is not enough. Customers of this system can search for a automobile; can purchase a automobile easily by selecting fast. On the other hand the stock of automobiles can be maintained perfectly by the automobile shop manager overcoming the drawbacks of existing system.
Welcome to WIPAC Monthly the magazine brought to you by the LinkedIn Group Water Industry Process Automation & Control.
In this month's edition, along with this month's industry news to celebrate the 13 years since the group was created we have articles including
A case study of the used of Advanced Process Control at the Wastewater Treatment works at Lleida in Spain
A look back on an article on smart wastewater networks in order to see how the industry has measured up in the interim around the adoption of Digital Transformation in the Water Industry.
COLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdfKamal Acharya
The College Bus Management system is completely developed by Visual Basic .NET Version. The application is connect with most secured database language MS SQL Server. The application is develop by using best combination of front-end and back-end languages. The application is totally design like flat user interface. This flat user interface is more attractive user interface in 2017. The application is gives more important to the system functionality. The application is to manage the student’s details, driver’s details, bus details, bus route details, bus fees details and more. The application has only one unit for admin. The admin can manage the entire application. The admin can login into the application by using username and password of the admin. The application is develop for big and small colleges. It is more user friendly for non-computer person. Even they can easily learn how to manage the application within hours. The application is more secure by the admin. The system will give an effective output for the VB.Net and SQL Server given as input to the system. The compiled java program given as input to the system, after scanning the program will generate different reports. The application generates the report for users. The admin can view and download the report of the data. The application deliver the excel format reports. Because, excel formatted reports is very easy to understand the income and expense of the college bus. This application is mainly develop for windows operating system users. In 2017, 73% of people enterprises are using windows operating system. So the application will easily install for all the windows operating system users. The application-developed size is very low. The application consumes very low space in disk. Therefore, the user can allocate very minimum local disk space for this application.
8. irb(main):001:0> bool
NameError: undefined local variable or method
`bool' for main:Object
from (irb):1
from /usr/bin/irb:12:in `<main>'
# Ок, это же язык с продвинутым ООП
34. irb(main):001:0> arr = ["1", "2", "3"]
=> ["1", "2", "3"]
irb(main):002:0> arr.map(&:String.new)
NoMethodError: undefined method `new' for
:String:Symbol
from (irb):26
from /usr/bin/irb:12:in `<main>'
# это было бы слишком элегантно
40. irb(main):001:0> load './chain.rb'
SyntaxError: /tmp/code.rb:4: syntax error,
unexpected '.', expecting end-of-input
.split(' ')
^
from (irb):15:in `load'
from (irb):15
from /usr/bin/irb:12:in `<main>'
# даже python так не делает
47. irb(main):001:0> String.new "x"
=> "x"
irb(main):002:0> String.new("x")
=> "x"
irb(main):003:0> String.new( "x" )
=> "x"
irb(main):004:0> String.new ("x")
48. irb(main):001:0> String.new "x"
=> "x"
irb(main):002:0> String.new("x")
=> "x"
irb(main):003:0> String.new( "x" )
=> "x"
irb(main):004:0> String.new ("x")
=> "x"
71. irb(main):001:0> h = {:foo => 1}
=> {:foo=>1}
irb(main):002:0> h = h.with_indifferent_access
=> {"foo"=>1}
irb(main):003:0> h["foo"]
=> 1
irb(main):004:0> h[:foo]
=> 1
# доступно только в rails
72. irb(main):001:0> h = {:foo => 1}
=> {:foo=>1}
irb(main):002:0> h = h.with_indifferent_access
=> {"foo"=>1}
irb(main):003:0> h["foo"]
=> 1
irb(main):004:0> h[:foo]
=> 1
# доступно только в rails
# ruby DSL для rails
73. def foo(&block)
puts 'open resource'
[*41..42].each &block.method(:call)
puts 'close resource'
end
foo do |value|
puts value
end
74. def foo(&block)
puts 'open resource'
[*41..42].each &block.method(:call)
puts 'close resource'
end
foo do |value|
puts value
end
> open resource
41
42
close resource
75. def foo(&block)
puts 'open resource'
[*41..42].each &block.method(:call)
puts 'close resource'
end
foo do |value|
puts value
break
end
76. def foo(&block)
puts 'open resource'
[*41..42].each &block.method(:call)
puts 'close resource'
end
foo do |value|
puts value
break
end
> open resource
41
77. def foo(&block)
puts 'open resource'
[*41..42].each &block.method(:call)
puts 'close resource'
end
def has_answer?
foo do |value|
return true if value == 42
end
end
puts has_answer?
78. def foo(&block)
puts 'open resource'
[*41..42].each &block.method(:call)
puts 'close resource'
end
def has_answer?
foo do |value|
return true if value == 42
end
end
puts has_answer?
> open resource
true
79. def foo(&block)
puts 'open resource'
[*41..42].each &block.method(:call)
puts 'close resource'
end
def has_answer?
rc = false
foo {|value| rc = true if value == 42}
rc
end
puts has_answer?
80. def foo(&block)
puts 'open resource'
[*41..42].each &block.method(:call)
puts 'close resource'
end
def has_answer?
rc = false
foo {|value| rc = true if value == 42}
rc
end
puts has_answer?
> open resource
close resource
true
82. module Foo
def bar
puts 'hi'
end
end
irb(main):009:0* Foo.bar
NoMethodError: undefined method `bar' for
Foo:Module
from (irb):9
from /usr/bin/irb:12:in `<main>'
84. module Foo
BAZ = 'hey'
module_function
def bar
puts 'hi'
end
end
85. module Foo
BAZ = 'hey'
module_function
def bar
puts 'hi'
end
end
irb(main):096:0> Foo::bar
86. module Foo
BAZ = 'hey'
module_function
def bar
puts 'hi'
end
end
irb(main):096:0> Foo::bar
hi
=> nil
87. module Foo
BAZ = 'hey'
module_function
def bar
puts 'hi'
end
end
irb(main):096:0> Foo::bar
hi
=> nil
irb(main):097:0> Foo::BAZ
88. module Foo
BAZ = 'hey'
module_function
def bar
puts 'hi'
end
end
irb(main):096:0> Foo::bar
hi
=> nil
irb(main):097:0> Foo::BAZ
=> "hey"
89. module Foo
BAZ = 'hey'
module_function
def bar
puts 'hi'
end
end
irb(main):096:0> Foo::bar
hi
=> nil
irb(main):097:0> Foo::BAZ
=> "hey"
irb(main):098:0> Foo.baz
90. module Foo
BAZ = 'hey'
module_function
def bar
puts 'hi'
end
end
irb(main):096:0> Foo::bar
hi
=> nil
irb(main):097:0> Foo::BAZ
=> "hey"
irb(main):098:0> Foo.baz
NoMethodError: undefined
method `baz' for Foo:Module
from (irb):98
from /usr/bin/irb:12:in
`<main>'
# почему нет?