3.20打卡day34

进阶2.回文数

问题描述

1221是一个非常特殊的数,它从左边读和从右边读是一样的,编程求大于等于n的所有这样的四位十进制数。

个人总结

本题可以枚举所有可能的千位 a(1 到 9),十位和百位 b(0 到 9),构造数num = a*1000 + b*100 + b*10 + a,然后判断num>=n就输出。

cpp 复制代码
#include <bits/stdc++.h>
using namespace std;



int main() {
    int n;
    cin >> n;

    for (int a = 1; a <= 9; a++) {
        for (int b = 0; b <= 9; b++) {
            int num = a * 1000 + b * 100 + b * 10 + a;
            if (num >= n) {
                cout << num << endl;
            }
        }
    }

    return 0;
}

计算机英语翻译

原文:

In recent years, pre-trained models have played an important role in artificial intelligence research. Researchers typically first train a general model using large-scale datasets and then fine-tune it on specific tasks. In this way, the model can utilize the knowledge learned during the pre-training stage to improve the performance of downstream tasks. For example, in the field of natural language processing, many language models are pre-trained on massive text corpora and achieve excellent results in tasks such as text classification, machine translation, and question answering. The pre-training and fine-tuning framework not only reduces training costs but also improves the generalization ability of models. Therefore, this approach has become an important paradigm in modern artificial intelligence research.

翻译:

近年来,预训练模型在人工智能研究中扮演了重要角色。研究者们通常首先使用大规模的数据集来训练一个总体的模型,然后在特定任务中进行微调。以这种方式,这个模型可以xx预训练阶段学到的知识来提升xx任务的表现。例如,在自然语言处理领域,许多语言模型在大量文本xx上进行预训练,并且在文本分类、机器翻译和问题回答等任务中取得优异的成功。预训练和微调架构不仅减少了训练开销而且提升了模型的总体能力。因此,这种方式已经成为现代人工智能研究的重要方式。

计算机英语单词扇贝打卡

相关推荐
Lsk_Smion2 分钟前
力扣实训 _ [207].课程表/图论
数据结构·leetcode·图论
孬甭_10 分钟前
深入剖析快速排序:原理、实现与性能优化
数据结构·算法·排序算法
San813_LDD12 分钟前
[数据结构]共享栈与双端队列:算法思想分析及C语言实现
java·开发语言·数据结构
Shadow(⊙o⊙)19 分钟前
QT常用控件1.0,enabled() geometry() QIcon的.qrc文件导入
开发语言·c++·qt
wuminyu23 分钟前
Java锁膨胀机制之偏向锁到轻量级锁源码剖析
java·linux·c语言·jvm·c++
阿正的梦工坊24 分钟前
【Rust】06-函数、控制流与模块组织
开发语言·算法·rust
葱卤山猪30 分钟前
二进制字节流序列化
c++·序列化
Lazionr30 分钟前
类和对象(中):对象生命周期与运算符重载
c++
阿正的梦工坊30 分钟前
【Rust】16-async/await、Future 与执行器模型
网络·算法·rust
凡人叶枫33 分钟前
Effective C++ 条款13:以对象管理资源(RAII)
java·linux·开发语言·c++·嵌入式开发