Skip to content

Instantly share code, notes, and snippets.

View rodion-m's full-sized avatar
🤩
CodeAliving

Rodion Mostovoi rodion-m

🤩
CodeAliving
View GitHub Profile
void main() {
const text = """She sells sea shells on the sea shore;
The shells that she sells are sea shells I'm sure.
So if she sells sea shells on the sea shore,
I'm sure that the shells are sea shore shells""";
var list = text.split(" ");
var wordsCount = list.length;
/*
Задание "Отсортировать карту в обратном порядке по ключам и вывести на экран результат." я понял как "отсортировать карту по ключу по убыванию".
Просьба проверять по всей строгости. Если нужно, готов дать объяснение к коду.
*/
void main() {
var numberBook = <String, int>{
"Иван": 2264865,
"Татьяна": 89523366684,
"Олег": 84952256575,
@rodion-m
rodion-m / CheckDigit.java
Created January 6, 2020 06:37
EAN13 Check Digit Validator (Java)
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You 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
*
using System;
using System.Globalization;
using MongoDB.Bson;
using MongoDB.Bson.Serialization;
using MongoDB.Bson.Serialization.Serializers;
namespace Main
{
public class DateTimeOffsetBsonSerializer : StructSerializerBase<DateTimeOffset>,
IRepresentationConfigurable<DateTimeOffsetBsonSerializer>