LEDGER(1) BSD General Commands Manual LEDGER(1)
NAME
ledger — Command-line, double-entry account reporting tool
SYNOPSIS
ledger [command] [options] [arguments]
DESCRIPTION
ledger is a command-line accounting tool based on the power and completeness of double-entry accounting. It is only a reporting tool, which means it never modifies your data files, but it does offer a large selection of reports, and different ways to customize them to your needs.
COMMANDS
ledger accepts several top-level commands, each of which generates a different kind of basic report. Most of them accept a report-query argument, in order to determine what should be reported. To understand the syntax of a report-query, see the section on QUERIES. In its most basic form, simply specifying one or more strings produces a report for all accounts containing those strings.
If no command is given, ledger enters a REPL, or command loop, allowing several commands to be executed on the same dataset without reparsing.
The following is a complete list of accepted reporting commands:
accounts [
report-query]
List all accounts for postings that match the report-query.
balance [
report-query]
Print a balance report showing totals for postings that match report-query, and aggregate totals for parents of those accounts. Options most commonly used with this command are:
−−basis (−B)
Report in terms of cost basis, not amount or value. This is the only form of report which is guaranteed to always balance to zero, when no report-query is specified. Only show totals for the top-most accounts.
−−empty (−E)
Show accounts whose total is zero.
−−flat
Rather than display a hierarchical tree, flatten the report to show subtotals for only accounts matching report-query.
−−no-total
Suppress the summary total shown at the bottom of the report.
The synonyms bal and b are also accepted.
budget [
report-query]
A special balance report which includes three extra columns: the amount budgeted during the reporting period, how spending differed from the budget, and the percentage of budget spent (exceeds 100% if you go over budget). Note that budgeting requires one or more ’’
periodic transactions ’’ to be defined in your data file(s). See the manual for more information.
cleared [
report-query]
A special balance report which adds two extra columns: the cleared balance for each account, and the date of the most recent cleared posting in that account. For this accounting to be meaningful, the cleared flag must be set on at least one posting. See the manual for more information.
commodities [
report-query]
List all commodities for postings matching the report-query.
convert
Reads data from a CSV (comma-separated values) file and generates ledger transactions.
csv [
report-query]
Report of postings matching the report-query in CSV format (comma-separated values). Useful for exporting data to a spreadsheet for further analysis or charting.
entry [
entry-template]
Generate and display a new, properly formatted ledger transaction by comparing the entry-template to the transactions in your data file(s). For more information on draft templates and using this command to quickly create new transactions, see the section ENTRIES.
The synonym xact is also accepted.
emacs [
query]
Output posting and transaction data in a format readily consumed by the Emacs editor, in a series of Lisp forms. This is used by the ledger.el Emacs mode to process reporting data from ledger.
equity [
report-query]
Print a transaction with a series of postings that balance current totals for accounts matching the report-query in a special account called Equity:Opening Balances. The purpose of this report is to close the books for a prior year, while using these equity postings to carry forward those balances.
org
Produce a journal file suitable for use in the Emacs org mode.
payees [
report-query]
List all payees for postings matching the report-query.
pricemap
Produce a file which can be used to generate a graph with graphviz showing the relationship of commodities in the ledger file.
prices [
report-query]
Report prices for all commodities in postings matching the report-query. The prices are reported with the granularity of a single day.
pricedb [
report-query]
Report prices for all commodities in postings matching the report-query. Prices are reported down to the second, using the same format as the ~/.pricedb file.
print [
report-query]
Print out the full transactions of any matching postings using the same format as they would appear in a data file. This can be used to extract subsets from a ledger file to transfer to other files.
push [
options]
In the REPL, push a set of command-line options, so that they will apply to all subsequent reports.
pop
In the REPL, pop any option settings that have been pushed.
register [
report-query]
List all postings matching the report-query. This is one of the most common commands, and can be used to provide a variety of useful reports. Options most commonly used with this command are:
−−average (−A)
Show the running average, rather than a running total.
−−current (−c)
Don’t show postings beyond the present day.
−−exchange commodity (−X)
Render all values in the given commodity, if a price conversion rate can be determined. Rates are always displayed relative to the date of the posting they are calculated for. This means a register report is a historical value report. For current values, it may be preferable to use the balance report.
−−gain (−G)
Show any gains (or losses) in commodity values over time.
−−head number
Only show the top number postings.
−−historical (−H)
Value commodities at the time of their acquisition.
−−invert
Invert the value of amounts shown.
−−market (−V)
Show current market values for all amounts. This is determined in a somewhat magical fashion. It is probably more straightforward to use −−exchange option.
−−period time-period (−p)
Show postings only for the given time-period.
−−related (−r)
Show postings that are related to those that would have been shown. It has the effect of displaying the "other side" of the postings.
−−sort value-expression (−S)
Sort postings by evaluating the given value-expression. Note that a comma-separated list of expressions is allowed, in which case each sorting term is used in order to determine the final ordering. For example, to search by date and then amount, one would use:
ledger reg --sort ’date, amount’
−−tail number
Only show the last number postings.
−−uncleared (−U)
Only show uncleared (i.e., recent) postings.
There are also several grouping options that can be useful:
−−by-payee (−P)
Group postings by common payee names.
−−daily (−D)
Group postings by day.
−−weekly (−W)
Group postings by week (starting on Sundays).
−−start-of-week day
Set the start of each report grouped by week to the given day.
−−monthly (−M)
Group postings by month.
−−quarterly
Group postings by fiscal quarter.
−−yearly (−Y)
Group postings by year.
−−days-of-week
Group postings by the day of the week on which they took place.
−−subtotal (−s)
Group all postings together. This is very similar to the totals shown by the balance report.
The synonyms reg and r are also accepted.
server
This command requires that Python support be active. If so, it starts up an HTTP server listening for requests on port 9000. This provides an alternate interface to creating and viewing reports. Note that this is very much a work-in-progress, and will not be fully functional until a later version.
select [
sql-query]
List all postings matching the sql-query. This command allows to generate SQL-like queries, e.g.:
ledger select date,amount from posts where account=~/Income/
source
Parse a journal file and checks it for errors. ledger will return success if no errors are found.
stats [
report-query]
Provide summary information about all the postings matching report-query. It provides information such as:
•
Time range of all matching postings
•
Unique payees
•
Unique accounts
•
Postings total
•
Uncleared postings
•
Days since last posting
•
Posts in the last 7 days
•
Posts in the last 30 days
•
Posts this month
xml [
report-query]
Output data relating to the current report in XML format. It includes all accounts and commodities involved in the report, plus the postings and the transactions they are contained in. See the manual for more information.
OPTIONS
−−abbrev-len INT
Set the minimum length an account can be abbreviated to if it doesn’t fit inside the account-width. If INT is zero, then the account name will be truncated on the right. If INT is greater than account-width then the account will be truncated on the left, with no shortening of the account names in order to fit into the desired width.
−−account EXPR
Prepend EXPR to all accounts reported. That is, the option −−account "’Personal’" would tack Personal: and −−account "tag(’VAT’)" would tack the value of the VAT tag to the beginning of every account reported in a balance or register report.
−−account-width INT
Set the width of the account column in the register report to INT characters.
−−actual (−L)
Report only real transactions, with no automated or virtual transactions used.
−−add-budget
Show only un-budgeted postings.
−−amount EXPR (−t)
Apply the given value expression to the posting amount. Using −−amount EXPR you can apply an arbitrary transformation to the postings.
−−amount-data (−j)
On a register report print only the dates and amount of postings. Useful for graphing and spreadsheet applications.
−−amount-width INT
Set the width in characters of the amount column in the register report.
−−anon
Anonymize registry output, mostly for sending in bug reports.
−−ansi
Use color if the terminal supports it. Alias for −−color
−−args-only
Ignore init files and environment variables for the ledger run.
−−auto-match
When generating a ledger transaction from a CSV file using the convert command, automatically match an account from the Ledger journal.
−−aux-date
Show auxiliary dates for all calculations. Alias for −−effective
−−average (−A)
Print average values over the number of transactions instead of running totals.
−−balance-format FMT
Specify the format to use for the balance report.
−−base
Reduce convertible commodities down the bottom of the conversion, e.g. display time in seconds.
−−basis (−B)
Report the cost basis on all posting. Alias for −−cost
−−begin DATE (−b)
Specify the start DATE of all calculations. Transactions before that date will be ignored.
−−bold-if EXPR
Print the entire line in bold if the given value expression is true.
−−budget
Only display budgeted items. In a register report this displays transaction in the budget, in a balance report this displays accounts in the budget.
−−budget-format FMT
Specify the format to use for the budget report.
−−by-payee (−P)
Group postings in the register report by common payee names.
−−check-payees
Enable strict and pedantic checking for payees as well as accounts, commodities and tags.
−−cleared (−C)
Display only cleared postings.
−−cleared-format FMT
Specify the format to use for the cleared report
−−collapse (−n)
Print only the top level accounts.
−−collapse-if-zero
Collapse the account display only if it has a zero balance.
−−color
Use color if the terminal supports it. Alias for −−ansi
−−columns INT
Make the register report INT characters wide. By default ledger will use all available columns in your terminal.
−−cost
Report the cost basis on all posting. Alias for −−basis.
−−count
Direct ledger to report the number of items when appended to the commodities, accounts or payees commands.
−−csv-format FMT
Format csv report according to FMT.
−−current (−c)
Shorthand for −−limit ’date <= today’.
−−daily (−D)
Shorthand for −−period daily.
−−date EXPR
Transform the date of the transaction using EXPR.
−−date-format DATEFMT (−y)
Print dates using DATEFMT. Refer to strftime(3) for details on the format string syntax.
−−datetime-format DATETIMEFMT
Print datetimes using DATETIMEFMT. Refer to strftime(3) for details on the format string syntax.
−−date-width INT
Specify the width, in characters, of the date column in the register report.
−−day-break
Break up register report of timelog entries that span multiple days by day.
−−days-of-week
Group transactions by the days of the week. Alias for −−dow.
−−dc
Display register or balance in debit/credit format If you use −−dc with either the register or balance commands, you will now get separate columns for debits and credits.
−−debug STR
If ledger has been built with debug options this will provide extra data during the run.
−−decimal-comma
Direct ledger to parse journals using the European standard comma as decimal separator, vice a period.
−−depth INT
Limit the depth of the account tree. In a balance report, for example, −−depth 2 will print balances only for accounts with two levels, i.e. Expenses:Entertainment but not Expenses:Entertainment:Dining. This is a display predicate, which means it only affects display, not the total calculations.
−−detail
Related to convert command. Synonym to −−rich-data option.
−−deviation
Report each posting’s deviation from the average. It is only meaningful in the register and prices reports.
−−display EXPR (−d)
Display lines that satisfy the expression EXPR.
−−display-amount EXPR
Apply a transformation to the displayed amount. This occurs after calculations occur.
−−display-total EXPR
Apply a transformation to the displayed total. This occurs after calculations occur.
−−dow
Group transactions by the days of the week. Alias for −−days-of-week.
−−download
Cause quotes to be automagically downloaded, as needed, by running a script named getquote and expecting that script to return a value understood by ledger. A sample implementation of a getquote script, implemented in Perl, is provided in the distribution. Downloaded quote price are then appended to the price database, usually specified using the environment variable LEDGER_PRICE_DB.
−−effective
Show auxiliary dates for all calculations. Alias for −−aux-date.
−−empty (−E)
Include empty accounts in report.
−−end DATE (−e)
Constrain the report so that transactions on or after DATE are not considered.
−−equity
Related to the equity command. Gives current account balances in the form of a register report.
−−exact
Report beginning and ending of periods by the date of the first and last posting occurring in that period.
−−exchange
COMMODITY [
, COMMODITY, ...] (−X)
Display values in terms of the given COMMODITY. The latest available price is used.
−−explicit
Direct ledger to require pre-declarations for entities (such as accounts, commodities and tags) rather than taking entities from cleared transactions as defined.
−−file FILE
Read journal data from FILE.
−−first INT
Print the first INT entries. Opposite of −−last INT. Alias for −−head.
−−flat
Force the full names of accounts to be used in the balance report. The balance report will not use an indented tree.
−−force-color
Output TTY color codes even if the TTY doesn’t support them. Useful for TTYs that don’t advertise their capabilities correctly.
−−force-pager
Force ledger to paginate its output.
−−forecast-while EXPR
Continue forecasting while VEXPR is true. Alias for −−forecast.
−−forecast-years INT
Forecast at most INT years into the future.
−−format FMT (−F)
Use the given format string FMT to print output.
−−gain (−G)
Report net gain or loss for commodities that have a price history.
−−generated
Include auto-generated postings (such as those from automated transactions) in the report, in cases where you normally wouldn’t want them.
−−group-by EXPR
Group transaction together in the register report. EXPR can be anything, although most common would be payee or commodity. The tag() function is also useful here.
−−group-title-format FMT
Set the format for the headers that separate reports section of a grouped report. Only has effect with a −−group-by EXPR register report.
−−head INT
Print the first INT entries. Opposite of −−tail INT. Alias for −−first
−−help
Print this man page.
−−immediate
Evaluate calculations immediately rather than lazily.
−−import FILE
Import FILE as Python module.
−−init-file FILE (−i)
Read FILE before any other ledger file. This file may not contain any postings, but it may contain option settings. To specify options in the init file, use the same syntax as the command-line, but put each option on its own line.
−−inject STR
Use STR amounts in calculations. In case you know what amount a transaction should be, but the actual transaction has the wrong value you can use metadata STR to specify the expected amount.
−−input-date-format DATEFMT
Specify the input date format for journal entries.
−−invert
Change the sign of all reported values.
−−last INT.
Report only the last INT entries. Opposite of −−first INT. Only useful on a register report. Alias for −−tail.
−−leeway INT (−Z)
Alias for −−price-expr.
−−limit EXPR (−l)
Limit postings in calculations.
−−lot-dates
Report the date on which each commodity in a balance report was purchased.
−−lot-notes
Report the tag attached to each commodity in a balance report.
−−lot-prices
Report the price at which each commodity in a balance report was purchased.
−−lots
Report the date and price at which each commodity was purchased in a balance report.
−−lots-actual
Preserve the uniqueness of commodities so they aren’t merged during reporting without printing the lot annotations.
−−market (−V)
Use the latest market value for all commodities.
−−master-account STR
Prepend all account names with STR
−−meta STR
In the register report, prepend the transaction with the value of the given tag STR.
−−meta-width INT
Specify the width of the Meta column used for the −−meta TAG options.
−−monthly (−M)
Shorthand for −−period monthly.
−−no-aliases
Aliases are completely ignored.
−−no-color
Suppress any color TTY output.
−−no-pager
Disables the pager on TTY output.
−−no-revalued
Stop ledger from showing <Revalued> postings.
−−no-rounding
Don’t output "<Adjustment>" postings. Note that this will cause the running total to often not add up! Its main use is for −−amount-data (−j) and −−total-data (−J) reports.
−−no-titles
Suppress the output of group titles.
−−no-total
Suppress printing the final total line in a balance report.
−−now DATE
Use DATE as the current date. This affects the output when using −−period, −−begin, −−end, or −−current to decide which dates lie in the past or future.
−−only EXPR
This is a postings predicate that applies after certain transforms have been executed, such as periodic gathering.
−−options
Display the options in effect for this ledger invocation, along with their values and the source of those values.
−−output FILE (−o)
Redirect the output of ledger to FILE.
−−pager STR
Use STR as the pager program.
−−payee
Sets a value expression for formatting the payee. In the register report this prevents the second entry from having a date and payee for each transaction.
−−payee-width INT
Set the number of columns dedicated to the payee in the register report to INT.
−−pedantic
Accounts, tags or commodities not previously declared will cause errors.
−−pending
Use only postings that are marked pending.
−−percent (−%)
Calculate the percentage value of each account in a balance reports. Only works for account that have a single commodity.
−−period PERIOD (−p)
Define a period expression that sets the time period during which transactions are to be accounted. For a register report only the transactions that satisfy the period expression with be displayed. For a balance report only those transactions will be accounted in the final balances.
−−period-sort
Sort the posting within transactions using the given value expression.
−−permissive
Quiet balance assertions.
−−pivot TAG
Produce a balance pivot report "around" the given TAG.
−−plot-amount-format FMT
Define the output format for an amount data plot.
−−plot-total-format FMT
Define the output format for a total data plot.
−−prepend-format FMT
Prepend FMT to every line of the output.
−−prepend-width INT
Reserve INT spaces at the beginning of each line of the output.
−−price (−I)
Use the price of the commodity purchase for performing calculations.
−−price-db FILE
−−price-exp STR (−Z)
Set the expected freshness of price quotes, in INT minutes. That is, if the last known quote for any commodity is older than this value, and if −−download is being used, then the Internet will be consulted again for a newer price. Otherwise, the old price is still considered to be fresh enough. Alias for −−leeway.
−−prices-format FMT
Set the format for the prices report.
−−pricedb-format FMT
Set the format expected for the historical price file.
−−primary-date
Show primary dates for all calculations. Alias for −−actual-dates
−−quantity (−O)
Report commodity totals (this is the default).
−−quarterly
Shorthand for −−period quarterly.
−−raw
In the print report, show transactions using the exact same syntax as specified by the user in their data file. Don’t do any massaging or interpreting. Can be useful for minor cleanups, like just aligning amounts.
−−real (−R)
Account using only real transactions ignoring virtual and automatic transactions.
−−recursive-aliases
Causes ledger to try to expand aliases recursively, i.e. try to expand the result of an earlier expansion again, until no more expansions apply.
−−register-format FMT
Define the output format for the register report.
−−related (−r)
In a register report show the related account. This is the other side of the transaction.
−−related-all
Show all postings in a transaction, similar to −−related but show both sides of each transaction.
−−revalued
Report discrepancy in values for manual reports by inserting <Revalued> postings. This is implied when using the −−exchange (−X) or −−market (−V) option.
−−revalued-only
Show only <Revalued> postings.
−−revalued-total
Display the sum of the revalued postings as the running total, which serves to show unrealized capital in a gain/losses report.
−−rich-data
When generating a ledger transaction from a CSV file using the convert command, add CSV, Imported, and UUID meta-data.
−−seed INT
Set the random seed to INT for the generate command. Used as part of development testing.
−−script FILE
Execute a ledger script.
−−sort EXPR (−S)
Sort the register report based on the value expression EXPR.
−−sort-xacts
Sort the posting within transactions using the given value expression.
−−start-of-week STR
Use STR as the particular day of the week to start when using the −−weekly option. STR can be day names, their abbreviations like "Mon", or the weekday number starting at 0 for Sunday.
−−strict
Accounts, tags or commodities not previously declared will cause warnings.
−−subtotal (−s)
Report register as a single subtotal.
−−tail INT
Report only the last INT entries. Only useful on a register report. Alias for −−last INT
−−time-colon
Display the value for commodities based on seconds as hours and minutes. Thus 8100s will be displayed as 2:15h instead of 2.25h.
−−time-report
Add two columns to the balance report to show the earliest checkin and checkout times for timelog entries.
−−total EXPR (−T)
Define a value expression used to calculate the total in reports.
−−total-data (−J)
Show only dates and totals to format the output for plots.
−−total-width INT
Set the width of the total field in the register report.
−−trace INT
Enable tracing. The INT specifies the level of trace desired.
−−truncate STR
Indicates how truncation should happen when the contents of columns exceed their width. Valid arguments for STR are leading, middle, and trailing. The default is smarter than any of these three, as it considers sub-names within the account name (that style is called "abbreviate").
−−unbudgeted
Show only un-budgeted postings.
−−uncleared (−U)
Use only uncleared transactions in calculations and reports.
−−unrealized
Show generated unrealized gain and loss accounts in the balance report.
−−unrealized-gains
Allow the user to specify what account name should be used for unrealized gains. Defaults to Equity:Unrealized Gains. Often set in one’s ~/.ledgerrc file to change the default.
−−unrealized-losses
Allow the user to specify what account name should be used for unrealized losses. Defaults to Equity:Unrealized Losses. Often set in one’s ~/.ledgerrc file to change the default.
−−unround
Perform all calculations without rounding and display results to full precision.
−−values
Show the values used by each tag when used in combination with the tags command.
−−value-expr EXPR
Set a global value expression annotation.
−−verbose
Print detailed information on the execution of ledger.
−−verify
Enable additional assertions during run-time. This causes a significant slowdown. When combined with −−debug CODE ledger will produce memory trace information.
−−verify-memory
Verify that every constructed object is properly destructed. This is for debugging purposes only.
−−version
Print version information and exit.
−−weekly (−W)
Shorthand for −−period weekly.
−−wide (−w)
Assume 132 columns instead of the TTY width.
−−yearly (−Y)
Shorthand for −−period yearly.
PRE-COMMANDS
Pre-commands are useful when you aren’t sure how a command or option will work. The difference between a pre-command and a regular command is that pre-commands ignore the journal data file completely, nor is the user’s init file read.
args / query
Evaluate the given arguments and report how ledger interprets it against the following model transaction:
2004/05/27 Book
Store
; This note applies to all postings. :SecondTag:
Expenses:Books 20 BOOK @ $10
; Metadata: Some Value
; Typed:: $100 + $200
; :ExampleTag:
; Here follows a note describing the posting.
Liabilities:MasterCard $-200.00
eval
Evaluate the given value expression against the model transaction.
format
Print details of how ledger uses the given formatting description and apply it against a model transaction.
parse / expr
Print details of how ledger uses the given value expression description and apply it against a model transaction.
generate
Randomly generates syntactically valid ledger data from a seed. Used by the GenerateTests harness for development testing.
period
Evaluate the given period and report how ledger interprets it.
template
Shows the insertion template that the xact command generates. This is a debugging command.
QUERIES
The syntax for reporting queries can get somewhat complex. It is a series of query terms with an implicit OR operator between them. The following terms are accepted:
regex
A bare string is taken as a regular expression matching the full account name. Thus, to report the current balance for all assets and liabilities, you would use:
ledger bal asset liab
payee regex (@regex)
Query on the payee, rather than the account.
tag regex (%regex)
note regex (=regex)
Query on anything found in an item’s note.
code regex (#regex)
Query on the xact’s optional code (which can be any string the user wishes).
term and term
Query terms are joined by an implicit OR operator. You can change this to AND by using the and keyword. For example, to show food expenditures occurring at Shakee’s Pizza, you could say:
ledger reg food and @Shakee
term or term
When you wish to be more explicit, use the OR operator.
show
not term
Reverse the logical meaning of the following term. This can be used with parentheses to great effect:
ledger reg food and @Shakee and not dining
( term )
If you wish to mix OR and AND operators, it is often helpful to surround logical units with parentheses. NOTE: Because of the way some shells interpret parentheses, you should always escape them:
ledger bal \( assets or liab \) and not food
EXPRESSIONS
abs(value)
Return the absolute value of the given value.
account
Return the posting’s account.
account_base
Return the base account, i.e. everything after the last account delimiter ’:’.
actual
Return true if the transaction is real, i.e not a automated or virtual transaction, false otherwise.
amount
Return the amount of the posting.
amount_expr
Return the calculated amount of the posting according to the −−amount option.
ansify_if(value, color, bool)
Render the given value as a string, applying the proper ANSI escape codes to display it in the given color if bool is true. It typically checks the value of the option −−color, for example:
ansify_if(amount, blue, options.color)
beg_line
Line number where entry for posting begins.
beg_pos
Character position where entry for posting begins.
ceiling(value)
Return the next integer of value toward +infinity.
cleared
Return true if the posting was cleared, false otherwise.
code
Return the transaction code, the string between the parenthesis after the date.
commodity(value)
Return the commodity of value or the posting amount when value was not specified.
date
Return the date of the posting.
end_line
Line number where entry for posting ends.
end_pos
Character position where entry for posting ends.
floor(value)
Return the next integer of value toward -infinity.
filename
The name of the ledger data file from whence the posting came.
format(string)
Evaluate string as format just like the −−format option.
format_date(date, format)
Return the date as a string using format. Refer to strftime(3) for format string details.
format_datetime(datetime, format)
Return the datetime as a string using format. Refer to strftime(3) for format string details.
get_at(seq, index)
Return value at index from seq. Used internally to construct different reports.
has_meta()
Return true if the posting has metadata named tag, false otherwise.
has_tag(tag)
Return true if the posting has metadata named tag, false otherwise.
is_seq(value)
Return true if value is a sequence. Used internally.
join(value)
Replace all newlines in value with \n.
justify(value, first_width, latter_width, right_justify, colorize)
Right or left justify the string representing value. The width of the field in the first line is given by first_width. For subsequent lines the width is given by latter_width. If latter_width is -1, first_width is used for all lines. If right_justify is true then the field is right justified within the width of the field. If it is false, then the field is left justified and padded to the full width of the field. If colorize is true, then ledger will honor color settings.
market(value, datetime)
Return the price of value at datetime. Note that datetime must be surrounded by brackets in order to be parsed correctly, e.g. [2012/03/23].
meta()
Return the value of metadata named name.
note
Return the note for the posting.
now
Return the current datetime.
options
A variable that allows access to the values of the given command-line options using the long option names, e.g. to see whether −−daily (−D) was given use option.daily.
payee
Return the payee of the posting.
percent(value_a, value_b)
Return the percentage of value_a in relation to value_b (used as 100%).
pending
Return true if the posting is marked as pending, false otherwise.
percent(value_a, value_b)
Return the percentage of value_a in relation to value_b.
print(value)
Print value to stdout. Used internally for debugging.
quantity(value)
Return the quantity of value for values that have a per-unit cost.
quoted(expression)
Surround expression with double-quotes.
real
Return true if the transaction is real, i.e not a automated or virtual transaction, false otherwise.
roundto(value, n)
Return value rounded to n digits. Does not affect formatting.
should_bold
Return true if expression given to −−bold-if evaluates to true. Internal use only!
scrub(value)
Clean value using various transformations such as round, stripping value annotations, and more.
strip(value)
Strip value annotation from value.
tag(name)
Return the value of tag named name.
to_amount(value)
Convert value to an amount. Internal use only!
to_balance(value)
Convert value to a balance. Internal use only!
to_boolean(value)
Convert value to a boolean. Internal use only!
to_date(value)
Convert value to a date. Internal use only!
to_datetime(value)
Convert value to a datetime. Internal use only!
to_int(value)
Return the integer value for value.
to_mask(value)
Convert value to a mask. Internal use only!
to_sequence(value)
Convert value to a sequence. Internal use only!
to_string(value)
Convert value to a character string.
today
Return today’s date.
total
Return the total of the posting.
total_expr
Return the calculated total of the posting according to the −−total option.
trim(value)
Trim leading and trailing whitespace from value.
truncated(string, total_len, account_len)
Truncate string to total_len ensuring that each account is at least account_len long.
virtual
Return true if the transaction is virtual, e.g automated, false otherwise.
DEBUG COMMANDS
In addition to the regular reporting commands, ledger also accepts several debug commands:
args [
report-query]
Display complete analysis of how ledger interpreted the given report-query. Useful if you want to understand how report queries are translated into value expressions.
eval [
value-expression]
Evaluate the given value-expression and prints the result. For more on value expressions, see the section EXPRESSIONS.
format [
format-string]
Display an analysis of how format-string was parsed, and what it would look like applied to a sample transaction. For more on format strings, see the section FORMATS.
generate
Generate 50 randomly composed yet valid ledger transactions.
parse [
value-expression]
Parse the given value-expression and display an analysis of the expression tree and its evaluated value. For more on value expressions, see the section EXPRESSIONS.
python [
file]
Invoke a Python interpreter to read the given file. What is special about this is that the ledger module is builtin, not read from disk, so it doesn’t require ledger to be installed anywhere, or the shared library variants to be built.
reload
Reload all data files for the current session immediately. Can only be used in the REPL.
template [
draft-template]
Display information about how draft-template was parsed. See the section on DRAFTS.
ENVIRONMENT
Every option to ledger may be set using an environment variable if the option has a long name. For example setting the environment variable LEDGER_DATE_FORMAT="%d.%m.%Y’ will have the same effect as specifying −−date-format ’%d.%m.%Y’ on the command-line. Options on the command-line always take precedence over environment variable settings, however.
FILES
~/.ledgerrc
Your personal ledger initializations.
SEE ALSO
beancount(1), hledger(1)
AUTHORS
John Wiegley 〈<EMAIL_ADDRESS>BSD March 23, 2012 BSD


18.
Now let's see if you tell me where I am...
Hint: I'm on an island both hot and cold and I wish I had enough money for a nice ice cold beer now.


UK parties attack rival spending plans in election feud
by The Associated PressLONDON (AP) — Britain’s biggest political parties are accusing each other of financial recklessness as they vie to win voters’ trust on the economy ahead of Britain’s Dec. 12 election.
The main opposition Labour Party accused the governing Conservatives on Sunday of spreading fake news with an eye-catching claim that Labour spending pledges will cost 1.2 trillion pounds ($1.5 trillion) over five years.
The figure is based on assuming a Labour government would implement every policy it has adopted in principle. Labour says not all those pledges will be in its official election platform.
Labour economy spokesman John McDonnell said the Conservative figure was “an incompetent mish-mash of debunked estimates and bad maths.”
Treasury chief Sajid Javid stood by the estimate, saying Labour’s proposals were “absolutely reckless.”
The Associated Press


| Package | com.sibirjak.angara.resource |
| Interface | public interface ICallback |
| Implementors | Callback |
It is possible to assign a callback function to any resource loader. If a callback has been specified, the callback will be executed before the resource loader COMPLETE event is dispatched. It is possible to mark a callback as asynchronous, which will stop the loader manager queue until the notifyComplete() method of that callback has been triggered.
Per default a callback method will be called synchronously. The loader manager continues working right after the callback handler has been triggered.
| Property | Defined by | ||
|---|---|---|---|
| loader : IResourceLoader
[read-only]
Returns a reference to the loader that defines the callback.
| ICallback |
| Method | Defined by | ||
|---|---|---|---|
|
notifyComplete():void
Notifies the loader manager about a completed asynchronous callback.
| ICallback | ||
|
setAsync():void
Sets a callback to be asynchronous.
| ICallback |
| loader | property |
loader:IResourceLoader
[read-only]Returns a reference to the loader that defines the callback.
Implementation public function get loader():IResourceLoader
| notifyComplete | () | method |
public function notifyComplete():void
Notifies the loader manager about a completed asynchronous callback.
The loader manager will continue loading not until this method has been called.
| setAsync | () | method |
public function setAsync():void
Sets a callback to be asynchronous.
The loader manager will wait for the callback completion to continue its work. You need to call callback.notifyComplete() to notify the loader manager to continue.


Many businesses have leftover food at the end of the day.

Site Currently in Construction, Please Check in later to see how we're doing.


Next: Reader Algorithm, Previous: Syntax, Up: Syntax
The Lisp reader takes characters from a stream, interprets them as a printed representation of an object, constructs that object, and returns it.
The syntax described by this chapter is called the standard syntax . Operations are provided by Common Lisp so that various aspects of the syntax information represented by a readtable can be modified under program control; see Reader. Except as explicitly stated otherwise, the syntax used throughout this document is standard syntax.
| • Readtables: | ||
| • Variables that affect the Lisp Reader: | ||
| • Standard Characters: | ||
| • Character Syntax Types: |


Welcome to the about me page.
I use br tags to create these line breaks, because
creating new paragraphs adds a bit more space.
My hobbies include code, chess, frisbee, and Yugioh. We can add teaching to that list now, I suppose!
These statements are styled with CSS. Each p element has the ID "aboutMe." Using IDs saves a lot of time if one decides to change the style for a certain element as s/he can avoid making line-by-line changes (worst case).
cursor:pointer; to make the cursor appear as if it can click on
these elements. However, clicking on these paragraphs won't do anything.
Thanks, CSS.


My name is David Rodriguez. I am a web developer with a heavy science background and a deep love for technology. After 10 years of exhilarating experience in retail, I changed my career path and followed my education for a rewarding change.
Find Out More
HTML, JavaScript.
CSS preprocessors SASS.
Frameworks AngularJS, React and jQuery.
Frameworks Bootstrap and Flexbox.
AJAX.
API design and development.
CRUD (Create, Read, Update, Delete).
RESTful Services.
Server-side languages like PHP, Python, Ruby,and JavaScript.
MySQL, PostgreSQL, and MongoDB.
Web server technology Node.js.
Server-side framework Express.js.
512-704-2920


Phing is a cross-platform PHP build tool, similar to Apache Ant.
A build tool helps you automate repetitive tasks.

You should automate everything you can.

Automating your processes will save you from your future self.
Maybe not today, maybe not tomorrow, but at some point you will make a mistake if it's not automated.
It's written in PHP, so if the rest of your project is PHP, you can run Phing.
Besides PHP, no other external dependencies are needed (such as Ruby or Java).
Great community support, with hundreds of different tasks.
github.com/phingofficial/phing
$> git clone https://github.com/phingofficial/phing.git
$> php phing\bin\phing
www.phing.info/trac/wiki/Users/Download
$> wget http://www.phing.info/get/phing-latest.phar -O phing.phar
$> php phing.phar
$> pear channel-discover pear.phing.info
$> pear install phing/phing
$> phing
composer.json:
{
"require": {
"phing/phing": "2.6.1"
}
}
$> php composer.phar install
Loading composer repositories with package information
Installing dependencies (including require-dev)
- Installing phing/phing (2.6.1)
Downloading: 100%
Writing lock file
Generating autoload files
$> php vendor\phing\phing\bin\phing
Phing is driven by XML files that define your projects, build targets, and individual tasks.
The XML format is very similar to Apache Ant.
A project is the root element of your XML.
The <project>
defines of all of your build targets and the tasks that will execute for the targets.
Only the default
attribut is required, which specifies the default target to run.
<?xml version="1.0" encoding="UTF-8"?>
A <target>
is a logical set of actions you want to take.
A <target>
can have tasks.
A <target>
can also have a list of other targets it depends on.
<?xml version="1.0" encoding="UTF-8"?>
<target name="build" depends="clean,lint,minify" />
<target name="clean">
<echo msg="I'm cleaning your build" />
</target>
<!-- ... -->
A task will take an action.
Tasks can be a core task that Phing ships with, or an external plug-in that you write.
<?xml version="1.0" encoding="UTF-8"?>
<echo msg="I'm cleaning your build" />
<delete dir="build" />
Some of the most useful:
append
, copy
, delete
, mkdir
condition
, foreach
, if
, fail
echo
, input
exec
, tstamp
, taskdef
git*
, svn*
, cvs*
ftpdeploy
, httpget
, mail
, s3put
, scp
, ssh
phpcodesniffer
, phpunit
, phpdocumentor
, jslint
, phpmd
A property is a variable.
Properties can come from built-in properties (Phing environment variables),
a build.properties
file, or created at runtime in your XML file via the <property>
element.
Use properties via the ${propertyname}
syntax.
<?xml version="1.0" encoding="UTF-8"?>
<property name="builddir" value="./build" />
<echo msg="I'm cleaning ${builddir}" />
<delete dir="${builddir}" />
There are many built-in properties:
application.startdir, env.*, host.arch, host.domain, host.fstype, host.name, host.os, host.os.release,
host.os.version, line.separator, os.name, phing.file, phing.dir, phing.home, phing.version, phing.project.name,
php.classpath, php.version, project.basedir, user.home
Simple key=value
format
# This is a comment in the .properties file
key=value
builddir=build
myapp.name=foo
myapp.url=http://foo.com
<?xml version="1.0" encoding="UTF-8"?>
<property file="./build.properties" />
<echo msg="I'm cleaning ${builddir} for ${myapp.name}" />
<delete dir="${builddir}" />
<property>
Define new properties in your XML.
<?xml version="1.0" encoding="UTF-8"?>
<property name="builddir" value="./build" />
<property name="cssdir" value="${build}/css" />
<property name="jsdir" value="${build}/js" />
<delete dir="${cssdir}" />
<delete dir="${jsdir}" />
<?xml version="1.0" encoding="UTF-8"?>
<echo msg="Hello" />
>$ phing echo
Buildfile: .\build.xml
my-project > echo:
[echo] Hello
BUILD FINISHED
Total time: 0.1780 seconds
<?xml version="1.0" encoding="UTF-8"?>
<target name="first" depends="second" />
<fail message="You messed up" />
>$ phing first
Buildfile: .\build.xml
my-project > second:
Execution of target "second" failed for the following reason:
.\build.xml:16:22: You messed up
BUILD FAILED
.\build.xml:16:22: You messed up
Total time: 0.1800 seconds
<?xml version="1.0" encoding="UTF-8"?>
<property name="deploy.hostname" value="foo.com" />
<exec
command="rsynz -avz ./ ${deploy.hostname}/"
dir="${project.basedir}"
checkreturn="true" />
<?xml version="1.0" encoding="UTF-8"?>
<taskdef
name="myprojecttask"
classpath="${project.basedir}"
classname="MyTask" /> <!-- ./MyTask.php -->
<myprojecttask message='hi' />
<?php
require_once 'phing/Task.php';
class MyTask extends Task {
protected $message;
// set from the task's attribute in the XML
public function setMessage($message) {
$this->message = $message;
}
// executed when task is called
public function main() {
echo $this->message;
}
}
$>phing externaltask
Buildfile: .\build.xml
[property] Loading .\build.properties
my-project > externaltask:
hi
BUILD FINISHED
Total time: 0.2930 seconds
<?xml version="1.0" encoding="UTF-8"?>
<target name="build" depends="clean,checkout,lint,
sniff,phpmd,test,doc,package" />
<target name="deploy" depends="build,pre-deploy,rsync,release" />
<target name="lint" depends="phplint,jslint,csslint" />
Phing is a great way to automate repetitive tasks.
Phing can be as simple or complex (and powerful) as you make it.
Phing can save time and reduce human error.
More Info:


MAGNOLIA **** (out of four stars) A review by Jamey Hughton
Starring-Jason Robards, Julianne Moore, Tom Cruise, Philip Baker Hall, John C. Reilly, Philip Seymour Hoffman, William H. Macy and Melora Walters Director-Paul Thomas Anderson Canadian Rating-14A Released by New Line Cinema - 01/00
MOVIE VIEWS by Jamey Hughton http://Welcome.to/MovieViews
Coincidence is a funny thing.
This is explained in the opening prologue of Paul Thomas Anderson's `Magnolia'. Our narrator (Ricky Jay) guides us through several unlikely scenarios of chance and coincidence that display, with great humor, how past relevance can intrude on the present. For instance: a man plummets off the side of a building in a suicide attempt, but is inflicted with a shotgun blast on his way to landing in netting that would have surely saved his life. The shotgun was fired by his mother from their apartment several floors below. With shotgun cocked, she was violently threatening her husband when the weapon accidentally fired and struck their son on his descent to the netting. But she insists that, to her knowledge, the gun was never loaded. Coincidentally, it was he - the suicide `victim' - had loaded the weapon a few weeks prior, hoping that it would end the feuding his parents had continued for years. `These strange things happen all the time,' the narrator concludes. P.T. Anderson has collected a photo album of lonely, troubled characters in an intersecting plot line that he uses to prove this thesis.
`Magnolia', a sprawling masterpiece of operatic grandeur, is an ambitious film in which the director's inventive jest never seems to stop flowing. Anderson leads us through several intertwining stories in Los Angeles, and each is fascinating for separate reasons. There is the story of cancer-stricken television producer Earl Partridge (Jason Robards), who lies on his deathbed, attended to by his unstable young wife (Julianne Moore) and a caring nurse (Philip Seymour Hoffman).  Frank has made himself an icon among males everywhere with his `Search and Destroy' program and his energized public seminars, in which he raucously lectures the audience on how to best invade female territory. There's the story of game show legend Jimmy Gator (Philip Baker Hall), who has hosted the beloved quiz show `What Do Kids Know?' for 30-odd years. Jimmy has also received the news that he is dying from cancer, and, in light of the fact his strength is deteriorating faster than anticipated, he tries to reunite with his daughter Claudia (Melora Walters). Meanwhile, current `What Do Kids Know?' contestant Stanley Spector (Jeremy Blackman) begins to notice his rigid father (Michael Bowen) sees him as merely a walking encyclopedia for cash income. And former child genius Donnie Smith (William H. Macy) ponders the misfortune of his job at an electronics store, and looks back at his brief and turbulent 15-minutes of fame.
Finally, there is the story of Jim Kurring (John C. Reilly), a mild-mannered police officer looking for love at age 32. In more ways than one, Anderson uses the Kurring character as the backbone of the story. He is kind and thoughtful where other characters are rough and violent, adding some emotional stability to the mix. As an ensemble piece, `Magnolia' is superbly crafted. The dignified and accomplished cast of actors balance their screen time miraculously, and each is given the spotlight at some pivotal time to properly voice their character's emotional dilemma. Everyone (or almost everyone) is successful in identifying with their character during these critical moments. Hall has a positively stunning, heart-wrenching breakdown on the game show, Robards is chillingly effective as he croaks out his untold confessions, and Walters is phenomenal throughout. However, the brunt of the recognition deserves to be bestowed upon Mr. Tom Cruise, who delivers a dazzling, high-voltage performance as Frank Mackey - the kinetic ball of vivacious energy at the center of Anderson's amazing concoction.
The cast is astonishing - but you knew that already. The outrageous kick behind `Magnolia' is writer-director Paul Thomas Anderson, a brilliant filmmaker who shows infinite ambition to plumb the emotional depths of this work in methods both extravagant and unique. Anderson received endless praise for `Boogie Nights', his detailed account of pornographic filmmaking in the 1970's. In `Magnolia', the director shows a keen and thoughtful eye for pacing. At just over 3-hours in length, the film could have been a tedious and pretentious experience, but it transforms into a moving, thrilling and audaciously funny spectacle under Anderson's wing. What David O. Russell did earlier this year with `Three Kings', P.T. Anderson achieves again here. By the time a totally outrageous, completely unexpected finale rolls around, you must acknowledge the fact that Paul Thomas Anderson is a bold and ambitious filmmaker, and `Magnolia' is a one-of-a-kind experience.
Another highlight is the soundtrack. Many scenes are accompanied by the music of Aimee Mann, including one expertly integrated segment in which the characters sing the lyrics of `Wise Up' in episodic fashion. The musical score, by Jon Brion, blends seamlessly into the fast-moving action in the 2nd act. But this is not necessarily a `viewer-friendly' movie. I can tell you right now, many audience members will be utterly confounded by the director's style - particularly the Biblical climax. Those who get involved in the film, though, will realize the treasure P.T. Anderson has delivered. `Magnolia' is a profound and effective motion picture, and a monumental achievement in film.
(C) 2000, Jamey Hughton
Your Comments Appreciated<EMAIL_ADDRESS>"Magnolia" is on my "Best & Worst of '99 - TOP TEN" http://Welcome.to/MovieViews MOVIE VIEWS by Jamey Hughton
The review above was posted to the
rec.arts.movies.reviews newsgroup (de.rec.film.kritiken for German reviews).
The Internet Movie Database accepts no responsibility for the contents of the
review and has no editorial control. Unless stated otherwise, the copyright
belongs to the author.
Please direct comments/criticisms of the review to relevant newsgroups.
Broken URLs inthe reviews are the responsibility of the author.
The formatting of the review is likely to differ from the original due
to ASCII to HTML conversion.
Related links: index of all rec.arts.movies.reviews reviews


Press the "Power On" button (1) to start playing the radio. You'll see that the label changes to "Power Off"; if you press it again, the radio will stop.
You can change frequency in several ways:
To change the band you are listening to, click on the band indicator (5). Note that, before you can listen to AM radio, you'll need to set up an upconverter in the settings window.
Click the "Save" button (6) to save the station you are listening to as a preset. Enter a name for the preset and press "Save".
To switch to a preset, click the preset selection box (7) and choose your new preset. The radio will switch to it immediately.
To delete a preset, switch to it and press the "Remove" button (8).
To change a preset's name, switch to it and click the "Save" button (6). Type the new name and press "Save".
To change the volume, click on the "loudspeaker" icon (9) and move the slider left and right to decrease or increase the volume. You can also use your mouse wheel on the icon to change volume directly.
To disable stereo click on the stereo indicator (10).
You can change a lot of settings by clicking on the "wrench" icon (11). There you can change several settings:
| Key | Function |
|---|---|
| Space Bar | Turn radio on/off |
| Up Arrow | Volume Up |
| Down Arrow | Volume Down |
| Left Arrow | Decrease Frequency |
| Right Arrow | Increase Frequency |
| < | Scan for stations by decreasing frequency |
| > | Scan for stations by increasing frequency |
| f | Edit frequency |
| b | Change band |
| s | Toggle stereo off/on |
| p | Go to preset selector |
| Shift + S | Save preset |
| Shift + R | Remove preset |
| ? | Help (this page) |
| ! | Settings menu |
Press Escape if the shortcuts don't work at first.


To access private endpoints in the BitMEX API, authentication is needed. First, an API key and secret need to be generated for the account you want to use with bitmexr
. For guidance see https://www.bitmex.com/app/restAPI#Authentication
When you have an API key, edit your .Renviron file and include both the key and secret.
Open .Renviron:
file.edit("~/.Renviron")
For a testnet API key use:
testnet_bitmex_apikey = "your testnet api key"
testnet_bitmex_apisecret = "your testnet api sectret"
For a live API key use:
bitmex_apikey = "your live api key"
bitmex_apisecret = "your live api sectret"
Make sure to restart your R session after making changes to the .Renviron file!
Functions in bitmexr
requiring authentication will use relevant key/secret when creating the encrypted signature to send to private API endpoints. You can use the testnet API to ensure the functions work as you’d expect prior to using the live API.
For more information about how the authentication process works see https://www.bitmex.com/app/apiKeysUsage.


Current location
Loading...
No-drone zones
Within:
kilometers
miles
Loading...
Source:
https://github.com/mapbox/drone-feedback/tree/master/sources/geojson


# Crichton, Admirable Source Configuration Management
# Copyright 2012 British Broadcasting Corporation
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
#
{% extends "admin/base_site.html" %}
{% comment %}
Admin change form.
Modified from django.contrib.admin.templates.object_history.html from Django 1.2.4.
Modified by Leo Simons for the BBC.
Modified to work for audit log data.
Copyright (c) 2011 BBC.
All rights reserved.
Portions copyright (c) Django Software Foundation and individual contributors.
All rights reserved.
Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
3. Neither the name of Django nor the names of its contributors may be used
to endorse or promote products derived from this software without
specific prior written permission.
 IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
"""
{% endcomment %}{% load i18n %}
{% block breadcrumbs %}
{% endblock %}
{% block content %}
{% if audit_list %}
| {% trans 'Date/time' %} |
{% trans 'User' %} |
{% trans 'Action' %} |
{% trans 'Data' %} |
{% for audit in audit_list %}
| {{ audit.action_date|date:"DATETIME_FORMAT" }} |
{{ audit.action_user.username|default:"system" }} |
{{ audit.action }} |
{{ audit.txt }} |
{% endfor %}
{% else %}
{% trans "This object doesn't have an audit log. It probably was added by editing the database directly." %}
{% endif %}
{% endblock %}


Web server in Go
https://github.com/Slashgear/go-server-example
Custom parameters for RGB color and text
Allowed type questions :
string, int, boolean, password, service, enum, multiline, certificate
Add question for port mapping
``` .catalog: name: GoColor version: 0.1.0 description: Example of go color uuid: gocolor-0 minimum_rancher_version: v0.56.0 questions: - variable: port label: port description: Port to show default: 80 required: true type: int ```
``` version: '2' services: ServerGoColor: image: slashgear/go-server-example stdin_open: true tty: true ports: - 80:${port}/tcp labels: io.rancher.container.pull_image: always ```
Generate config files structures to avoid errors.


It may take several minutes to come back and during that time systems might
be inaccessible.
Please provide your passcode below to proceed.


Program 04 - Using for loop
Write a program to print the sum of the series 2+4+6.....+n.
package main
import (
"bufio"
"fmt"
"os"
"strconv"
"strings"
)
func main() {
reader := bufio.NewReader(os.Stdin)
fmt.Println("Enter the value of numberN")
numberN, _ := reader.ReadString('\n')
numberN = strings.TrimSpace(numberN)
intNumberN, _ := strconv.Atoi(numberN)
sum := 0
temp := 0
for counter := 0; counter <= intNumberN; counter++ {
sum = sum + temp
temp = temp + 2
}
fmt.Println("sum of",intNumberN,"series:",sum)
}
Output:
Enter the value of numberN
5
sum of 5 series: 30
Explanation:
In this program, we calculate the sum of series 2+4+6.....+n number
condition : Starting first term of a series is equal to 2
using (for loop). We take the value of 'n'from user as an input
upto which user want the sum of series.
As an output we calculate the sum of series.
Accordingly to the user input value.


| 994 | (A) | To holde þat þay highte hafe and thaire hertis noghte to change |
| 999 | (C) | To holde þat þey hyȝte haue . þat neuur her hertes turne |
| 981 | (D) | To help þat þei hit have & neuer her hertis chaunge |
| 961 | (E) | to hoolde þat þei hyȝte . & neuyr her hertys chaunge |
| (Ex) | ---- no text ---- |
| 1019 | (L) | To hold þat þey byhot han & neuer here herte chaunge |
| 934 | (P) | T o halde þa t þai heght h??? ? neuer þair hert ch????? |
| 972 | (U) | To holden that thei hight haue / and neuer hert chaunge |
| 59 | (V) | To holden þat they hight and neuer her hertes chaunge |